Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

✨🍫 Add CocoaPods podspec #132

Merged
merged 3 commits into from
Jul 5, 2018
Merged

✨🍫 Add CocoaPods podspec #132

merged 3 commits into from
Jul 5, 2018

Conversation

phatblat
Copy link
Member

@phatblat phatblat commented Jul 5, 2018

While working on mas-cli/mas#154 I noticed that Commandant doesn't support CocoaPods, so I created a podspec. This works, but I can clean it up if this is a direction you want to go in.

I see that this project supports Carthage and the SwiftPM, would you like to add CocoaPods? If so, the final step is to publish the spec to trunk. I am more than happy to help out and make sure the core contributors can all update the pod on release.

So, the cost of adding CocoaPods support is pretty low, but specifically involves the following:

  • the pod is built on CI (pod lib lint) to prevent regressions
  • dependency changes will need to be mirrored across
    • Cartfile*
    • Package.swift
    • Commandant.podspec
  • on release
    1. the version is updated in the .podspec file
    2. the new pod version is published to trunk using pod trunk push Commandant.podspec by a contributor with permission to do so

Thoughts?

@phatblat
Copy link
Member Author

phatblat commented Jul 5, 2018

Oh, LOL. I didn't see #122 🤦‍♂️

@mdiep
Copy link
Member

mdiep commented Jul 5, 2018

This looks great. 👍

@mdiep mdiep merged commit 21c23c3 into Carthage:master Jul 5, 2018
@mdiep
Copy link
Member

mdiep commented Jul 5, 2018

Do you want to be in charge of pushing the podspec? Do I need to give you access to the repo to do that?

@phatblat phatblat deleted the cocoapods branch July 6, 2018 01:50
@phatblat
Copy link
Member Author

phatblat commented Jul 6, 2018

Sure, I'll take care of pushing the spec to trunk. I'll also open an issue to track adding others to have access to publish updates.

@phatblat
Copy link
Member Author

phatblat commented Jul 6, 2018

No, I don't need repo access to be able to publish the spec. In fact, the spec doesn't even need to be tracked in source control to publish, but obviously that's a best practice.

I would like to become a contributor on this project as I'm starting another macOS CLI project and could help maintain it.

@phatblat phatblat mentioned this pull request Jul 6, 2018
@phatblat
Copy link
Member Author

phatblat commented Jul 6, 2018

It's live! https://cocoapods.org/pods/Commandant

$ pod trunk push Commandant.podspec
Updating spec repo `master`
Validating podspec
 -> Commandant (0.14.0)

Updating spec repo `master`

--------------------------------------------------------------------------------
 🎉  Congrats

 🚀  Commandant (0.14.0) successfully published
 📅  July 5th, 20:03
 🌎  https://cocoapods.org/pods/Commandant
 👍  Tell your friends!
--------------------------------------------------------------------------------

$ pod trunk info Commandant

Commandant
    - Versions:
      - 0.14.0 (2018-07-06 02:03:27 UTC)
    - Owners:
      - Ben Chatelain <ben@octop.ad>

$ pod search Commandant --no-pager

-> Commandant (0.14.0)
   Type-safe command line argument handling
   pod 'Commandant', '~> 0.14.0'
   - Homepage: https://github.com/Carthage/Commandant
   - Source:   https://github.com/Carthage/Commandant.git
   - Versions: 0.14.0 [master repo]

@ikesyo
Copy link
Member

ikesyo commented Jul 6, 2018

Thanks @phatblat! Could you add me as the pod owner as well? My mail address is here: https://github.com/ikesyo.


# s.xcconfig = { "HEADER_SEARCH_PATHS" => "$(SDKROOT)/usr/include/libxml2" }

s.dependency "Result", "~> 4.0"
Copy link
Member

@ikesyo ikesyo Jul 6, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is actually wrong. At 0.14.0 this should be ~ 3.2.

https://github.com/Carthage/Commandant/blob/0.14.0/Cartfile#L1

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The dependencies are updated in #130 and not released yet.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok, the spec can be patched

@phatblat
Copy link
Member Author

phatblat commented Jul 6, 2018

@ikesyo done! 🙌🏻

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants