remove /Pods folder
[카테고리:] pod
When you accidentally installed cocoa pod beta version
//This installs beta version
sudo gem install cocoapods --pre
sudo gem uninstall cocoapods
sudo gem install cocoapods
How to remove a pod library
pod install: it doesn’t update pod libraries
if you are just adding/removing pods
pod update [PODNAME]
only when you want to update pods to a newer version.
https://guides.cocoapods.org/using/pod-install-vs-update.html
What ~> pod file
Well,
~>
(the optimistic operator) is used when you want to specify a version ‘up to next major | minor | patch‘. For example:
~> 0.1.2
will get you a version up to 0.2 (but not including 0.2 and higher)
~> 0.1
will get you a version up to 1.0 (but not including 1.0 and higher)
~> 0
will get you a version of 0 and higher (same as if it was omitted)where
0.1.2
would mean ‘I want this exact version’
Removing pod libraries from source control
- Remove pod libraries from source control
- Remove pod libraries from source control
- add gitignore /Pods
- Even if you remove the files, the files that were pushed and changed before adding to ignore are kept under tracking
- git rm -r –cached .
- https://git-scm.com/docs/git-rm
- -r: Allow recursive removal when a leading directory name is given.
- –cached: Use this option to unstage and remove paths only from the index. Working tree files, whether modified or not, will be left alone.
- git add .
- push the change
- git rm -r –cached .
- Others when pull the change
- remove Pods folder
- pull the change
- pod install -repo update
Things to check before adding Library
1. All files are under 100MB
-> If not, you need to use LFS or ignore library files from git. LFS also bills for bandwidth of the file. It’s easy to exceed free 1GB limit.
https://git-scm.com/docs/git-rm
2. Testability
-> Check if the library has network request and response code, and if you can mock the network easily
How to check version of pod libraries
pod outdated
CocoaPods how to install only one new library
pod install --no-repo-update
but it also update cocoa pod ( you can check it on Podfile.lock COCOAPODS: ~ line)
update cocoapods to specific version
sudo gem install cocoapods -v 1.3.1
to resolve
[!] The version of CocoaPods used to generate the lockfile (1.3.1) is higher than the version of the current executable (1.1.1). Incompatibility issues may arise.
warning
bundle format unrecognized, invalid, or unsuitable
/Users/~~/Library/Developer/Xcode/DerivedData/HwaHae-hccdoyunthsapaetucitltuiyufg/Build/Products/Debug-iphoneos/~~.app/Frameworks/Result.framework: bundle format unrecognized, invalid, or unsuitable
Command /bin/sh failed with exit code 1
-> Clean Build Folder resolved this issue