当前位置: 首页 > 工具软件 > Ruby/Git > 使用案例 >

.rvm/rubies/ruby-2.3.3/lib/ruby/2.3.0/rubygems/...:in `require':

李言
2023-12-01

在生成pod模板库是发现一个错误导致模板库生成错误:
.rvm/rubies/ruby-2.3.3/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require’: cannot load such file – colored2 (LoadError)

输入上面提示的colored2的两条gem命令即可解决问题
$ sudo gem install colored2

中间会提示输入密码
$ sudo gem update –system

完成后继续执行自己的命令
$ pod lib create XXXlib

RubyGems system software updated
likexue的Mac-Pro:SelectArea likexue$ pod lib create KXSelectArea
Cloning https://github.com/CocoaPods/pod-template.git into KXSelectArea.
Configuring KXSelectArea template.
security: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.
! Before you can create a new library we need to setup your git credentials.
security: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.

What is your name?

likexue

! Setting your name in git to likexue
git config user.name “likexue”


To get you started we need to ask a few questions, this should only take a minute.

If this is your first time we recommend running through with the guide:
- http://guides.cocoapods.org/making/using-pod-lib-create.html
( hold cmd and double click links to open in a browser. )

What language do you want to use?? [ Swift / ObjC ]

Objc

Would you like to include a demo application with your library? [ Yes / No ]

yes

Which testing frameworks will you use? [ Specta / Kiwi / None ]

None

Would you like to do view based testing? [ Yes / No ]

no

What is your class prefix?

KX
security: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.
security: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.
security: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.
security: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.
security: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.
security: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.

Running pod install on your new library.

Analyzing dependencies
Fetching podspec for KXSelectArea from ../
Downloading dependencies
Installing KXSelectArea (0.1.0)
Generating Pods project
Integrating client project

[!] Please close any current Xcode sessions and use KXSelectArea.xcworkspace for this project from now on.
Sending stats
Pod installation complete! There is 1 dependency from the Podfile and 1 total pod installed.

Ace! you’re ready to go!
We will start you off by opening your project in Xcode
open ‘KXSelectArea/Example/KXSelectArea.xcworkspace’
To learn more about the template see https://github.com/CocoaPods/pod-template.git.
To learn more about creating a new pod, see
http://guides.cocoapods.org/making/making-a-cocoapod.
likexue的Mac-Pro:SelectArea likexue$

 类似资料: