3

I have already a projects in which cocoapod was working fine previously but somehow now when I am trying to include new file. I am getting below error.

/Users/username/.podenv/libexec/../libexec/podenv-exec: line 31: /Users/username/.podenv/versions/1.0.1/bin/pod: No such file or directory

I was trying to delete MyProject.xcworkspace and Podfile so that I can reinstall Podfile but again getting above error.

pableiros
  • 14,932
  • 12
  • 99
  • 105
Gaurav Pandey
  • 1,953
  • 3
  • 23
  • 37
  • 6
    see this http://stackoverflow.com/questions/26990057/cocoapods-commands-fail-due-to-no-such-file-or-directory-dir-initialize-us – Anbu.Karthik Aug 30 '16 at 13:35

1 Answers1

6

My guess is that you somehow deleted the cocoapods itself rather then project and Podfile of specific project, kindly re install the cocoapods by following below commands:

  1. Open Terminal.
  2. Enter command:

    $ sudo gem install cocoapods
    
  3. Create new Xcode project.

  4. Navigate to directory containing Xcode project. Use:

     cd ../directory-location/.. 
    

    or cd [drag-and-drop project folder]

  5. Enter command to create the Podfile:

    $ pod init
    
  6. Enter command

    $ pod install
    
pableiros
  • 14,932
  • 12
  • 99
  • 105