Skip to content

Instantly share code, notes, and snippets.

@soxjke
Last active October 26, 2017 10:19
Show Gist options
  • Save soxjke/abfeb50c60b6cf6b8d6453e2b88072d6 to your computer and use it in GitHub Desktop.
Save soxjke/abfeb50c60b6cf6b8d6453e2b88072d6 to your computer and use it in GitHub Desktop.
Podfile for weather app
source 'https://github.com/CocoaPods/Specs.git'
use_frameworks!
inhibit_all_warnings!
def common_pods
pod 'Redux-ReactiveSwift', '~> 0.1.1' # Our Redux library
pod 'ReactiveCocoa', '~> 7.0.0-alpha1' # ReactiveCocoa has necessary UI bindings
pod 'ObjectMapper', '3.0.0' # ObjectMapper is for fast from/to JSON transformations
end
def test_pods
pod 'Quick', '1.2.0' # Quick is BDD-like Specs framework for XCode unit testing
pod 'Nimble', '7.0.2' # Nimble is a set of matchers for XCode unit testing
end
def app_pods
pod 'Alamofire', '4.5.1' # Alamofire is library we will use for network requests
pod 'SnapKit', '4.0.0' # A Swift Autolayout DSL for iOS & OS X
end
test_targets = ['Simple-Weather-AppTests']
app_targets = ['Simple-Weather-App']
test_targets.each { |targetName|
target targetName do
common_pods
test_pods
end
}
app_targets.each { |targetName|
target targetName do
common_pods
app_pods
end
}
# Since we're integrating alpha version of ReactiveCocoa we tweak SWIFT_VERSION
# By the final 7.0 release in November there won't be any need in tweaking SWIFT_VERSION
post_install do |installer|
installer.pods_project.targets.each do |target|
if target.name == 'ReactiveCocoa'
target.build_configurations.each do |config|
config.build_settings['SWIFT_VERSION'] = '3.2'
end
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment