Ios 在没有Xcode项目的情况下将cocoapod添加到Swift游乐场
我想将cocoapod添加到Swift游乐场,但我尝试运行Ios 在没有Xcode项目的情况下将cocoapod添加到Swift游乐场,ios,swift,cocoapods,xcode9,swift-playground,Ios,Swift,Cocoapods,Xcode9,Swift Playground,我想将cocoapod添加到Swift游乐场,但我尝试运行pod init,但出现以下错误: Errno::ENOENT - No such file or directory @ dir_initialize - /Applications/Xcode.app/Contents/Developer/Library/Xcode/Templates/File Templates/Source/Playground with Platform Choice.xctemplate /Library/R
pod init
,但出现以下错误:
Errno::ENOENT - No such file or directory @ dir_initialize - /Applications/Xcode.app/Contents/Developer/Library/Xcode/Templates/File Templates/Source/Playground with Platform Choice.xctemplate
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/generate.rb:43:in `open'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/generate.rb:43:in `foreach'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/generate.rb:43:in `dir_for_platform'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/generate.rb:10:in `initialize'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/workspace.rb:26:in `new'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/workspace.rb:26:in `block in generate'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/workspace.rb:23:in `chdir'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/workspace.rb:23:in `generate'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/command/playgrounds.rb:46:in `run'
/Library/Ruby/Gems/2.3.0/gems/claide-1.0.2/lib/claide/command.rb:334:in `run'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.5.0/lib/cocoapods/command.rb:52:in `run'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.5.0/bin/pod:55:in `<top (required)>'
/usr/local/bin/pod:22:in `load'
/usr/local/bin/pod:22:in `<main>'
[!]未找到Xcode项目,请指定一个
我试着解决这个问题
gem安装cocoapods游乐场
Errno::ENOENT - No such file or directory @ dir_initialize - /Applications/Xcode.app/Contents/Developer/Library/Xcode/Templates/File Templates/Source/Playground with Platform Choice.xctemplate
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/generate.rb:43:in `open'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/generate.rb:43:in `foreach'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/generate.rb:43:in `dir_for_platform'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/generate.rb:10:in `initialize'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/workspace.rb:26:in `new'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/workspace.rb:26:in `block in generate'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/workspace.rb:23:in `chdir'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/workspace.rb:23:in `generate'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/command/playgrounds.rb:46:in `run'
/Library/Ruby/Gems/2.3.0/gems/claide-1.0.2/lib/claide/command.rb:334:in `run'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.5.0/lib/cocoapods/command.rb:52:in `run'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.5.0/bin/pod:55:in `<top (required)>'
/usr/local/bin/pod:22:in `load'
/usr/local/bin/pod:22:in `<main>'
Errno::enoint-没有这样的文件或目录@dir\u initialize-/Applications/Xcode.app/Contents/Developer/Library/Xcode/Templates/file Templates/Source/playerd with Platform Choice.xctemplate
/Library/Ruby/Gems/2.3.0/Gems/cocoapods-playgrounds-1.2.2/lib/cocoapods playgrounds/generate.rb:43:在“开放”中
/Library/Ruby/Gems/2.3.0/Gems/cocoapods-playgrounds-1.2.2/lib/cocoapods playgrounds/generate.rb:43:in'foreach'
/Library/Ruby/Gems/2.3.0/Gems/cocoapods-playgrounds-1.2.2/lib/cocoapods playgrounds/generate.rb:43:in'dir_for_platform'
/Library/Ruby/Gems/2.3.0/Gems/cocoapods-playgrounds-1.2.2/lib/cocoapods playgrounds/generate.rb:10:in'initialize'
/Library/Ruby/Gems/2.3.0/Gems/cocoapods-playgrounds-1.2.2/lib/cocoapods playgrounds/workspace.rb:26:in'new'
/Library/Ruby/Gems/2.3.0/Gems/cocoapods-playgrounds-1.2.2/lib/cocoapods playgrounds/workspace.rb:26:in“生成中的块”
/Library/Ruby/Gems/2.3.0/Gems/cocoapods-playgrounds-1.2.2/lib/cocoapods playgrounds/workspace.rb:23:in'chdir'
/Library/Ruby/Gems/2.3.0/Gems/cocoapods-playgrounds-1.2.2/lib/cocoapods playgrounds/workspace.rb:23:in“generate”
/Library/Ruby/Gems/2.3.0/Gems/cocoapods-playgrounds-1.2.2/lib/cocoapods-playgrounds/command/playgrounds.rb:46:in'run'
/Library/Ruby/Gems/2.3.0/Gems/claide-1.0.2/lib/claide/command.rb:334:in'run'
/Library/Ruby/Gems/2.3.0/Gems/cocoapods-1.5.0/lib/cocoapods/command.rb:52:in'run'
/Library/Ruby/Gems/2.3.0/Gems/cocoapods-1.5.0/bin/pod:55:in`'
/usr/local/bin/pod:22:in“装载”
/usr/local/bin/pod:22:in`'
你们中有人知道如何解决这个错误吗?看看这个线程:可能重复更新ruby,然后更新gem
CoCoCoapods游乐场
@PranavKasetti该线程下有一条长达一年的评论说框架不能与Xcode9一起工作,其git repo也已存档,那么,你真的用Xcode9测试过它了吗?它对你有用吗?啊,没有检查。那可以解释很多!在这种情况下,我建议您发布一个答案,以获得一些学分。:)