Cocoapods 명령은“이러한 파일이나 디렉토리가 없습니다. @ dir_initialize-/ Users //.cocoapods/repos(Errno::ENOENT)”
아래의 스택 추적에서 오류를 해결하도록 도와 줄 수 있습니까? 이것은 pod명령을 실행할 때 발생합니다 . 운없이 보석을 제거하고 다시 설치했습니다.
00:44:05-David~/dev/farecast-app (master)$ pod setup
Setting up CocoaPods master repo
/usr/local/rvm/rubies/ruby-2.1.0/lib/ruby/2.1.0/pathname.rb:422:in `open': No such file or directory @ dir_initialize - /Users/David/.cocoapods/repos (Errno::ENOENT)
from /usr/local/rvm/rubies/ruby-2.1.0/lib/ruby/2.1.0/pathname.rb:422:in `foreach'
from /usr/local/rvm/rubies/ruby-2.1.0/lib/ruby/2.1.0/pathname.rb:422:in `children'
from /usr/local/rvm/gems/ruby-2.1.0/gems/cocoapods-0.34.4/lib/cocoapods/sources_manager.rb:63:in `all'
from /usr/local/rvm/gems/ruby-2.1.0/gems/cocoapods-0.34.4/lib/cocoapods/user_interface/error_report.rb:127:in `repo_information'
from /usr/local/rvm/gems/ruby-2.1.0/gems/cocoapods-0.34.4/lib/cocoapods/user_interface/error_report.rb:34:in `report'
from /usr/local/rvm/gems/ruby-2.1.0/gems/cocoapods-0.34.4/lib/cocoapods/command.rb:63:in `report_error'
from /usr/local/rvm/gems/ruby-2.1.0@global/gems/claide-0.7.0/lib/claide/command.rb:300:in `handle_exception'
from /usr/local/rvm/gems/ruby-2.1.0@global/gems/claide-0.7.0/lib/claide/command.rb:274:in `rescue in run'
from /usr/local/rvm/gems/ruby-2.1.0@global/gems/claide-0.7.0/lib/claide/command.rb:264:in `run'
from /usr/local/rvm/gems/ruby-2.1.0/gems/cocoapods-0.34.4/lib/cocoapods/command.rb:50:in `run'
from /usr/local/rvm/gems/ruby-2.1.0/gems/cocoapods-0.34.4/bin/pod:33:in `<top (required)>'
from /usr/local/rvm/gems/ruby-2.1.0/bin/pod:23:in `load'
from /usr/local/rvm/gems/ruby-2.1.0/bin/pod:23:in `<main>'
from /usr/local/rvm/gems/ruby-2.1.0/bin/ruby_executable_hooks:15:in `eval'
from /usr/local/rvm/gems/ruby-2.1.0/bin/ruby_executable_hooks:15:in `<main>'
업데이트 : @KeithSmiley의 제안으로 수정되었습니다.
나는 같은 문제가 있었고 달리고 pod setup나서 고쳤다.pod install
Cocoapods는 github 저장소가 손상되어 사용자가 로컬 저장소를 수동으로 정리하도록 하는 문제 가있었습니다.
오류를 자세히 설명하는 Cocoapods 블로그 게시물 의 인용문 :
불행히도 우리는 libgit2에서 버그가 발생하여 Specs 저장소로 강제 푸시해야 할 것입니다. ( '마스터'사양 저장소라고도 함)
이것이 당신에게 무엇을 의미합니까? 기본적으로 CocoaPods 설정이 중단됩니다. 스펙 저장소의 로컬 사본을 수동으로 삭제하고 새 버전의 스펙 저장소를 다시 복제해야합니다. 다음 명령을 사용하여이를 수행 할 수 있습니다.
해결책:
$ sudo rm -fr ~/.cocoapods/repos/master
$ pod setup
위의 명령을 실행하면 손상된 저장소를 제거하고 깨끗한 저장소를 사용하여 다시 초기화 할 수 있습니다. 자세한 내용 은 위에서 언급 한 블로그 게시물 을 참조하십시오.
도움이 되었기를 바랍니다!
비슷한 문제가있었습니다. 포드 폴더를 삭제하고 포드 설치를 다시 실행했습니다. 문제 해결됨.
아무것도 나를 위해 일 sudo gem install cocoapods하지 않았다 , 나는 마술을했다.
Podfile 또는 Podspec에서 잘못된 아포스트로피 문자를 사용할 때 가끔 발생합니다.

Those apostrophes are default when using standard TextEdit app on OS X. I prefer Sublime Text to avoid such errors
QUICK SOLUTION
A good way to solve this issue is going to specified folder and check for the file that is missing (sometimes it is there but in a rare format) and delete the file. Remove also Podfile.lock file
Then execute pod install and everything should be fine :) you don't need to remove all repos that Cocoapods have downloaded.
Done!
Tried a ton of stuff and the only fix for me was saying
brew install cocoapods
and then
brew link --overwrite cocoapods
Now it seems to be working fine.
FYI - I ran into this issue on a fresh install of cocoapods. Sounds like it's a bug that is fixed in 0.36
https://github.com/CocoaPods/guides.cocoapods.org/issues/58
I got a similar error. And I tried "pod setup", not working. Then I create a fake file which I was told missing, and then "pod update", works.
go to project directory and type command export PATH=$PATH:$HOME/Software/ruby/bin
I got the same problem, but I had to delete whole ./Pods/ directory in my project to be able to continue (the directory contained symlinks to files from other branch that were not deleted on branch switch)
I know this is an older post, but I ran into this problem when moving or deleting a .h file in a local pod. Turns out this was an issue with v0.38 and the solution was to update.
See the Github issue discussion of it here.
'IT story' 카테고리의 다른 글
| 따옴표와 따옴표가없는 객체 키의 차이점은 무엇입니까? (0) | 2020.05.10 |
|---|---|
| 일반적으로 어떤 머신 러닝 분류기를 선택해야합니까? (0) | 2020.05.10 |
| 루비 : 해시를 HTTP 매개 변수로 바꾸는 방법? (0) | 2020.05.09 |
| Composer를 실행하면“입력 파일을 열 수 없습니다 : composer.phar” (0) | 2020.05.09 |
| Bash를 사용하여 텍스트 파일에 데이터를 열고 쓰시겠습니까? (0) | 2020.05.09 |