From 296d79be864d4e946151832abf6ad907810b316c Mon Sep 17 00:00:00 2001 From: Andrew Bennet Date: Wed, 3 Apr 2019 19:05:46 +0100 Subject: [PATCH] Add support for Eureka 5.0+ (#62) --- .travis.yml | 6 +++--- Cartfile | 2 +- Cartfile.resolved | 6 +++--- Example/Example.xcodeproj/project.pbxproj | 2 +- ImageRow.podspec | 8 ++++---- ImageRow.xcodeproj/project.pbxproj | 22 +++++++++------------- README.md | 10 +++++----- Tests/ImageRowTests.swift | 6 +++--- 8 files changed, 29 insertions(+), 33 deletions(-) diff --git a/.travis.yml b/.travis.yml index c76fc79..b8b24e5 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,13 +1,13 @@ language: objective-c -osx_image: xcode10 +osx_image: xcode10.2 env: -- DESTINATION="OS=12.0,name=iPhone 8" SCHEME="ImageRow" SDK=iphonesimulator +- DESTINATION="OS=12.2,name=iPhone 8" SCHEME="ImageRow" SDK=iphonesimulator before_install: - brew update - brew outdated carthage || brew upgrade carthage - carthage update --platform iOS -- gem install xcpretty --no-rdoc --no-ri --no-document --quiet +- gem install xcpretty --no-document --quiet script: - xcodebuild clean build -project ImageRow.xcodeproj -scheme "$SCHEME" -sdk "$SDK" -destination "$DESTINATION" -configuration Debug ONLY_ACTIVE_ARCH=NO test | xcpretty -c diff --git a/Cartfile b/Cartfile index ec2bbb1..299dd1b 100644 --- a/Cartfile +++ b/Cartfile @@ -1 +1 @@ -github "xmartlabs/Eureka" ~> 4.0 +github "xmartlabs/Eureka" ~> 5.0 diff --git a/Cartfile.resolved b/Cartfile.resolved index eb50540..7e80ea9 100644 --- a/Cartfile.resolved +++ b/Cartfile.resolved @@ -1,3 +1,3 @@ -github "Quick/Nimble" "v7.3.1" -github "Quick/Quick" "v1.3.2" -github "xmartlabs/Eureka" "4.3.1" +github "Quick/Nimble" "v8.0.1" +github "Quick/Quick" "v2.0.0" +github "xmartlabs/Eureka" "5.0.0" diff --git a/Example/Example.xcodeproj/project.pbxproj b/Example/Example.xcodeproj/project.pbxproj index 61ae997..00dd1d5 100644 --- a/Example/Example.xcodeproj/project.pbxproj +++ b/Example/Example.xcodeproj/project.pbxproj @@ -176,7 +176,7 @@ }; buildConfigurationList = 28F828C71C4B714D00330CF4 /* Build configuration list for PBXProject "Example" */; compatibilityVersion = "Xcode 3.2"; - developmentRegion = English; + developmentRegion = en; hasScannedForEncodings = 0; knownRegions = ( en, diff --git a/ImageRow.podspec b/ImageRow.podspec index 46ed04c..ff2603c 100644 --- a/ImageRow.podspec +++ b/ImageRow.podspec @@ -1,15 +1,15 @@ Pod::Spec.new do |s| s.name = "ImageRow" - s.version = "3.2.0" + s.version = "4.0.0" s.summary = "Eureka row that allows us to take or select a picture." s.homepage = "https://github.com/EurekaCommunity/ImageRow" s.license = { type: 'MIT', file: 'LICENSE' } s.author = { "Xmartlabs SRL" => "swift@xmartlabs.com" } s.source = { git: "https://github.com/EurekaCommunity/ImageRow.git", tag: s.version.to_s } s.social_media_url = 'https://twitter.com/EurekaCommunity' - s.ios.deployment_target = '9.0' + s.ios.deployment_target = '9.3' s.requires_arc = true s.ios.source_files = 'Sources/**/*.{swift}' - s.dependency 'Eureka', '~> 4.3' - s.swift_version = "4.2" + s.dependency 'Eureka', '~> 5.0' + s.swift_version = "5.0" end diff --git a/ImageRow.xcodeproj/project.pbxproj b/ImageRow.xcodeproj/project.pbxproj index 7968b9e..40badf8 100644 --- a/ImageRow.xcodeproj/project.pbxproj +++ b/ImageRow.xcodeproj/project.pbxproj @@ -172,17 +172,17 @@ TargetAttributes = { 28F8287C1C494B2C00330CF4 = { CreatedOnToolsVersion = 7.2; - LastSwiftMigration = 0900; + LastSwiftMigration = 1020; }; 28F828861C494B2C00330CF4 = { CreatedOnToolsVersion = 7.2; - LastSwiftMigration = 0900; + LastSwiftMigration = 1020; }; }; }; buildConfigurationList = 28F828771C494B2C00330CF4 /* Build configuration list for PBXProject "ImageRow" */; compatibilityVersion = "Xcode 3.2"; - developmentRegion = English; + developmentRegion = en; hasScannedForEncodings = 0; knownRegions = ( en, @@ -292,7 +292,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 8.0; + IPHONEOS_DEPLOYMENT_TARGET = 9.3; MTL_ENABLE_DEBUG_INFO = YES; ONLY_ACTIVE_ARCH = YES; SDKROOT = iphoneos; @@ -344,7 +344,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 8.0; + IPHONEOS_DEPLOYMENT_TARGET = 9.3; MTL_ENABLE_DEBUG_INFO = NO; SDKROOT = iphoneos; SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; @@ -375,8 +375,7 @@ PRODUCT_NAME = "$(TARGET_NAME)"; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; - SWIFT_SWIFT3_OBJC_INFERENCE = Default; - SWIFT_VERSION = 4.2; + SWIFT_VERSION = 5.0; }; name = Debug; }; @@ -399,8 +398,7 @@ PRODUCT_BUNDLE_IDENTIFIER = com.xmartlabs.ImageRow; PRODUCT_NAME = "$(TARGET_NAME)"; SKIP_INSTALL = YES; - SWIFT_SWIFT3_OBJC_INFERENCE = Default; - SWIFT_VERSION = 4.2; + SWIFT_VERSION = 5.0; }; name = Release; }; @@ -418,8 +416,7 @@ PRODUCT_BUNDLE_IDENTIFIER = com.xmartlabs.ImageRowTests; PRODUCT_NAME = "$(TARGET_NAME)"; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; - SWIFT_SWIFT3_OBJC_INFERENCE = Default; - SWIFT_VERSION = 4.0; + SWIFT_VERSION = 5.0; }; name = Debug; }; @@ -436,8 +433,7 @@ LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = com.xmartlabs.ImageRowTests; PRODUCT_NAME = "$(TARGET_NAME)"; - SWIFT_SWIFT3_OBJC_INFERENCE = Default; - SWIFT_VERSION = 4.0; + SWIFT_VERSION = 5.0; }; name = Release; }; diff --git a/README.md b/README.md index ed01670..1e5a8ef 100644 --- a/README.md +++ b/README.md @@ -60,9 +60,9 @@ You must add the **NSPhotoLibraryUsageDescription** and **NSCameraUsageDescript ## Requirements -* iOS 9.0+ -* Xcode 9.0+ -* Eureka ~> 4.0 +* iOS 9.3+ +* Xcode 10.2+ +* Eureka ~> 5.0 ## Getting involved @@ -89,7 +89,7 @@ You can also experiment and learn with the *ImageRow Playground* which is contai To install ImageRow, simply add the following line to your Podfile: ```ruby -pod 'ImageRow', '~> 3.0' +pod 'ImageRow', '~> 4.0' ``` #### Carthage @@ -99,7 +99,7 @@ pod 'ImageRow', '~> 3.0' To install ImageRow, simply add the following line to your Cartfile: ```ogdl -github "EurekaCommunity/ImageRow" ~> 3.0 +github "EurekaCommunity/ImageRow" ~> 4.0 ``` ## Customization diff --git a/Tests/ImageRowTests.swift b/Tests/ImageRowTests.swift index a404d52..60f306c 100644 --- a/Tests/ImageRowTests.swift +++ b/Tests/ImageRowTests.swift @@ -68,9 +68,9 @@ class ImageRowTests: XCTestCase { } func testImagePickerControllerSourceTypeRawValue() { - XCTAssert(UIImagePickerControllerSourceType.photoLibrary.rawValue == ImageRowSourceTypes.PhotoLibrary.imagePickerControllerSourceTypeRawValue) - XCTAssert(UIImagePickerControllerSourceType.camera.rawValue == ImageRowSourceTypes.Camera.imagePickerControllerSourceTypeRawValue) - XCTAssert(UIImagePickerControllerSourceType.savedPhotosAlbum.rawValue == ImageRowSourceTypes.SavedPhotosAlbum.imagePickerControllerSourceTypeRawValue) + XCTAssert(UIImagePickerController.SourceType.photoLibrary.rawValue == ImageRowSourceTypes.PhotoLibrary.imagePickerControllerSourceTypeRawValue) + XCTAssert(UIImagePickerController.SourceType.camera.rawValue == ImageRowSourceTypes.Camera.imagePickerControllerSourceTypeRawValue) + XCTAssert(UIImagePickerController.SourceType.savedPhotosAlbum.rawValue == ImageRowSourceTypes.SavedPhotosAlbum.imagePickerControllerSourceTypeRawValue) } func testImageRow() {