XCode and CocoaPods commands, shortcuts and other utilities for my iOS projects :D
Last active
February 22, 2023 00:44
-
-
Save cleonps/e295939d13768b32b0f3990d3f3a0c44 to your computer and use it in GitHub Desktop.
XCode Tips
- Close XCode and simulators
- Open terminal:
xcrun simctl erase all
- Close XCode and simulators
- Open terminal and list devices, then replace device_ID with the corresponding ID:
xcrun simctl list
xcrun simctl erase device_ID
- Close XCode and simulators
- Open terminal:
xcrun simctl --set previews delete all
Remove some cached files that the "Clean Build Folder" option can't remove (From Finder: shift+command+G)
- Delete the folder DerivedData OR all contents:
~/Library/Developer/XCode/DerivedData
- If you already have some XCode Snippets, move the "CodeSnippets" folder into your iCloud. It could be at the iCloud's root directory or at any directory.
- Then create a symbolic link from the folder "CodeSnippets" to your "~/Library/Developer/Xcode/UserData" folder. To copy the full path to your "CodeSnippets" folder, just drag it into the terminal.
ln -s "full-path-to/CodeSnippets" ~/Library/Developer/Xcode/UserData - If you need your snippets from another machine, just create the symbolic link to your iCloud again
- Only needed the first time
sudo gem install cocoapods
- Go to root project folder from terminal
pod init - Edit the Podfile (I'm using Sublime Text, replace for your text editor)
open -a "Sublime Text" Podfile - Add your pods and save the file, then install pods from terminal
pod install
- Go to root project folder from terminal
pod update
- Go to root project folder from terminal (Replace PodName)
pod update PodName
- Go to root project folder from terminal
pod outdated
- Open Podfile and add
inhibit_all_warnings!
- Open Podfile and add (Replace PodName)
pod 'PodName', : inhibit_warnings => true
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment