-
Notifications
You must be signed in to change notification settings - Fork 106
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Carthage support #226
Add Carthage support #226
Conversation
Right now the |
@thoughtbot/ios Any thoughts on this? |
Oh, yeah, sorry. I do have thoughts. I really want Carthage support. It bothers me that we don't have it already. But I'm also thinking that the better long term solution would be to remove explicit CocoaPods support, and instead make dependency management completely generic. So for example, we could provide a This might (will) cause issues with some current implementations that explicitly look for cocoapods support. For example, the Settings bundle stuff is fairly tightly coupled to the current implementation. But I do think this is a better long-term solution. |
@gfontenot I was thinking it would be nice to not duplicate all this logic as I was writing it but didn't want to change everything at once. As a middle ground between the current state of this and what you're thinking, what do you think about for now extracting the dependency stuff into a single class so we remove this duplication, and come back later and couple it less? |
Sounds like a reasonable plan. I realize that what I'm asking for is a much larger undertaking. |
This is the first step in removing specific dependency managers from liftoff. Based on [this conversation](#226 (comment))
f1242f5
to
0d0ac8c
Compare
This is the first step in removing specific dependency managers from liftoff. Based on [this conversation](#226 (comment))
This is the first step in removing specific dependency managers from liftoff. Based on [this conversation](#226 (comment))
opts.on('--dependency-managers [NAME(s)]', 'Comma separated list of dependency managers to enable. Available options: cocoapods,carthage') do |list| | ||
@options[:dependency_managers] = (list || "").split(",") | ||
end | ||
|
||
opts.on('--[no-]cocoapods', 'Enable/Disable Cocoapods') do |use_cocoapods| |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wasn't sure if I should remove this option or not. It wouldn't break people's liftoffrc but if there were a script that passes in options this needs to be here. Thoughts?
@gfontenot Did the extraction 8625e6e, let me know what you think. It should still maintain compatibility with anyone using the |
generate_templates | ||
generate_settings | ||
install_cocoapods | ||
install_dependency_managers |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe install_dependencies
?
This is really really great. I think for the Cartfile, we can at least add |
@gfontenot Unfortunately that adds a lot of extra complexity to this PR. With that in mind I'd prefer to keep away from that for now. |
👯 |
Added carthage as a dependency manager. What it does: - Adds an empty `Cartfile` - Runs `carthage update` - Adds the `copy-frameworks.sh` build phase to the project - Adds `carthage update` to `bin/setup` script
Added a
--carthage
option that's disabled by default to provide backwardscompatibility.
What this option does:
Cartfile
carthage update
copy-frameworks.sh
build phase to the projectcarthage update
tobin/setup
script