Skip to content
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

Centralize deployment target #123

Merged
merged 1 commit into from
Mar 20, 2014
Merged

Centralize deployment target #123

merged 1 commit into from
Mar 20, 2014

Conversation

gfontenot
Copy link
Member

  • Set the deployment target at the project level instead of at the
    target level. This mimics the behavior of Xcode.
  • Configure the deployment target with ProjectConfiguration.
  • Use the deployment target information to populate values inside
    templates.

target.build_configurations.each do |configuration|
configuration.build_settings.delete('OTHER_LDFLAGS')
configuration.build_settings.delete('IPHONEOS_DEPLOYMENT_TARGET')
Copy link
Contributor

Choose a reason for hiding this comment

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

why would you need to delete this setting, only to set it later? (line 75)

Copy link
Member Author

Choose a reason for hiding this comment

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

This is deleting the default that Xcodeproj sets at the target level (4.3 by default). When we set it later, we're setting it at the project level instead.

@tonyd256
Copy link
Contributor

👍

the target should default to the latest base version (currently 7.0) ... changes for that can be done once the project is opened IMO

@@ -3,6 +3,8 @@ class ProjectConfiguration
attr_accessor :project_name, :company, :prefix, :configure_git, :warnings_as_errors, :install_todo_script, :enable_static_analyzer, :indentation_level, :warnings, :application_target_groups, :unit_test_target_groups, :use_cocoapods
attr_writer :author, :company_identifier

LATEST_IOS = 7.0
Copy link

Choose a reason for hiding this comment

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

According to our guides:

Order model contents: constants, macros, public methods, private methods

While this was in the [rails](Order model contents: constants, macros, public methods, private methods) section, it probably applies to ruby as well

I would put the constant right below the class name, above the attr_accessor macros

- Set the deployment target at the project level instead of at the
  target level. This mimics the behavior of Xcode.
- Configure the deployment target with ProjectConfiguration.
- Use the deployment target information to populate values inside
  templates.
@JoelQ
Copy link

JoelQ commented Mar 20, 2014

👍

@gfontenot gfontenot merged commit 25fcc00 into master Mar 20, 2014
@gfontenot gfontenot deleted the gf-deployment-target branch March 20, 2014 14:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants