Skip to content

Instantly share code, notes, and snippets.

@Geoffrey-T
Last active April 18, 2018 13:01
Show Gist options
  • Save Geoffrey-T/935321056b211121da7888f89ac4282e to your computer and use it in GitHub Desktop.
Save Geoffrey-T/935321056b211121da7888f89ac4282e to your computer and use it in GitHub Desktop.
Create Private Pod snippets

Create Pod

pod lib create YOUR_POD
git remote add origin your_repository_link
git push -u origin master

Edit your PodSpec:

  • Fill s.summary
  • Fill s.description(it must be longer than summury)
  • Check s.source (adress of you pod repository)
  • If you use framework like UIKit, don't forget to add it on podspec s.frameworks = 'UIKit', ...

Check podspec is valid

pod lib lint

If you use private pod and libraries add :

pod lib lint ~/.cocoapods/repos/YOUR_REPO ./YOUR_PODSPEC.podspec --allow-warnings --sources='PRIVATE_REPOSITORY.git,https://github.com/CocoaPods/Specs' --use-libraries

Create release

  • Go to github, on your pod repository
  • Go to release
  • Create new release 0.1.0 (version must be the same in your podspec)

Push podspec

pod repo push PODSPEC_FOLDER YOUR_PODSPEC.podspec

Podspec folder is in ~/.cocoapods/repos/PODSPEC_FOLDER

If you have not podspec repository follow this link

Enjoy :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment