Skip to content

Commit 22c8b49

Browse files
authored
Merge pull request #30 from imagekit-developer/develop
2 parents 0bbec69 + 01bb65d commit 22c8b49

37 files changed

+403
-135
lines changed

.github/workflows/main.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,12 @@ jobs:
2222
- name: Build Example Project
2323
run: |
2424
cd Example
25-
xcodebuild -workspace ImageKit.xcworkspace -scheme ImageKit-Example -destination 'platform=iOS Simulator,name=iPhone 15' clean build CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO
25+
xcodebuild -workspace ImageKit.xcworkspace -scheme ImageKit-Example -destination 'platform=iOS Simulator,name=iPhone 17' clean build CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO
2626
2727
- name: Run Tests
2828
run: |
2929
cd Example
30-
xcodebuild -workspace ImageKit.xcworkspace -scheme ImageKit-Example -destination 'platform=iOS Simulator,name=iPhone 15' -enableCodeCoverage YES clean test CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO
30+
xcodebuild -workspace ImageKit.xcworkspace -scheme ImageKit-Example -destination 'platform=iOS Simulator,name=iPhone 17' -enableCodeCoverage YES clean test CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO
3131
3232
- name: Upload Coverage to codecov
3333
run: bash <(curl -s https://codecov.io/bash) -J '^ImageKitIO$' -X coveragepy

.gitignore

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,4 +37,8 @@ Carthage/Build
3737
Pods/*
3838
Example/Pods/*
3939
Server/node_modules
40-
Server/*.lock
40+
Server/*.lock
41+
42+
#Swift package build outputs
43+
.swiftpm
44+
.build/

.swiftpm/xcode/package.xcworkspace/contents.xcworkspacedata

Lines changed: 7 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Example/ImageKit.xcodeproj/project.pbxproj

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,7 @@
160160
TargetAttributes = {
161161
607FACCF1AFB9204008FA782 = {
162162
CreatedOnToolsVersion = 6.3.1;
163+
DevelopmentTeam = FY66VYM646;
163164
LastSwiftMigration = 0900;
164165
};
165166
};
@@ -385,11 +386,12 @@
385386
baseConfigurationReference = 7661EF116E06444B352B18F0 /* Pods-ImageKit_Example.debug.xcconfig */;
386387
buildSettings = {
387388
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
389+
DEVELOPMENT_TEAM = FY66VYM646;
388390
INFOPLIST_FILE = ImageKit/Info.plist;
389-
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
391+
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
390392
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
391393
MODULE_NAME = ExampleApp;
392-
PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.demo.$(PRODUCT_NAME:rfc1034identifier)";
394+
PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.demo.--PRODUCT-NAME-";
393395
PRODUCT_NAME = "$(TARGET_NAME)";
394396
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
395397
SWIFT_VERSION = 4.0;
@@ -401,11 +403,12 @@
401403
baseConfigurationReference = BFEF935EF71672E4888B2B32 /* Pods-ImageKit_Example.release.xcconfig */;
402404
buildSettings = {
403405
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
406+
DEVELOPMENT_TEAM = FY66VYM646;
404407
INFOPLIST_FILE = ImageKit/Info.plist;
405-
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
408+
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
406409
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
407410
MODULE_NAME = ExampleApp;
408-
PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.demo.$(PRODUCT_NAME:rfc1034identifier)";
411+
PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.demo.--PRODUCT-NAME-";
409412
PRODUCT_NAME = "$(TARGET_NAME)";
410413
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
411414
SWIFT_VERSION = 4.0;

Example/Podfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ end
77
post_install do |installer|
88
installer.pods_project.targets.each do |target|
99
target.build_configurations.each do |config|
10-
config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '12.0'
10+
config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '13.0'
1111
end
1212
end
1313
installer.pods_project.targets.each do |target|

Example/Podfile.lock

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
PODS:
2-
- ImageKitIO (3.0.0)
3-
- ImageKitIO/Tests (3.0.0):
2+
- ImageKitIO (3.1.0)
3+
- ImageKitIO/Tests (3.1.0):
44
- Mocker (~> 2.5)
55
- Nimble (~> 10.0.0)
66
- Quick (~> 5.0.1)
@@ -23,11 +23,11 @@ EXTERNAL SOURCES:
2323
:path: "../"
2424

2525
SPEC CHECKSUMS:
26-
ImageKitIO: 804da6f03a903c4f540d6a3c0dd8ee87e9f29040
26+
ImageKitIO: 9cb4bb64a800a248f0f60ed5070458bd3e6ac61a
2727
Mocker: 8c731a8104962f246cadf2b02556218e9edc1390
2828
Nimble: 5316ef81a170ce87baf72dd961f22f89a602ff84
2929
Quick: 749aa754fd1e7d984f2000fe051e18a3a9809179
3030

31-
PODFILE CHECKSUM: 406170311ac5dd5482330203b884d5db8ef323c7
31+
PODFILE CHECKSUM: 8224e8c767b2e111bf4f338e9aaa55d7cd447b9e
3232

33-
COCOAPODS: 1.15.2
33+
COCOAPODS: 1.16.2

ImageKitIO.podspec

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Pod::Spec.new do |s|
22
s.name = 'ImageKitIO'
3-
s.version = '3.0.0'
3+
s.version = '3.1.0'
44
s.summary = 'iOS SDK for ImageKit.io'
55

66

@@ -14,13 +14,16 @@ ImageKit is a complete image optimization and transformation solution that comes
1414
s.author = { 'ImageKit Developer' => 'developer@imagekit.io', 'ahnv' => 'abhinav@imagekit.io' }
1515
s.source = { :git => 'https://github.com/imagekit-developer/imagekit-ios.git', :tag => s.version.to_s }
1616

17-
s.swift_version = '4.0'
18-
s.ios.deployment_target = '12.0'
17+
s.swift_version = '6.0'
18+
s.ios.deployment_target = '13.0'
1919

20-
s.source_files = 'ImageKit/**/*'
20+
s.source_files = 'Sources/ImageKit/**/*'
2121

2222
s.test_spec 'Tests' do |test_spec|
2323
test_spec.source_files = 'Tests/**/*'
24+
test_spec.resource_bundles = {
25+
"ImageKitIO_ImageKitIO-Tests" => ["Tests/fixtures/**"]
26+
}
2427
test_spec.dependency 'Quick', '~> 5.0.1'
2528
test_spec.dependency 'Nimble', '~> 10.0.0'
2629
test_spec.dependency 'Mocker', '~> 2.5'

Package.resolved

Lines changed: 60 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Package.swift

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
// swift-tools-version: 6.1
2+
// The swift-tools-version declares the minimum version of Swift required to build this package.
3+
4+
import PackageDescription
5+
6+
let package = Package(
7+
name: "ImageKitIO",
8+
platforms: [.iOS(.v13)],
9+
products: [
10+
// Products define the executables and libraries a package produces, making them visible to other packages.
11+
.library(
12+
name: "ImageKitIO",
13+
targets: ["ImageKitIO"]),
14+
],
15+
dependencies: [
16+
.package(url: "https://github.com/Quick/Quick.git", from: "5.0.1"),
17+
.package(url: "https://github.com/Quick/Nimble.git", from: "10.0.0"),
18+
.package(url: "https://github.com/WeTransfer/Mocker.git", from: "2.5.0"),
19+
.package(url: "https://github.com/httpswift/swifter.git", from: "1.5.0")
20+
],
21+
targets: [
22+
// Targets are the basic building blocks of a package, defining a module or a test suite.
23+
// Targets can depend on other targets in this package and products from dependencies.
24+
.target(
25+
name: "ImageKitIO",
26+
path: "Sources",
27+
),
28+
.testTarget(
29+
name: "ImageKitIO-Tests",
30+
dependencies: ["ImageKitIO", "Quick", "Nimble", "Mocker", .product(name: "Swifter", package: "swifter")],
31+
path: "Tests",
32+
resources: [.process("fixtures")]
33+
),
34+
]
35+
)

README.md

Lines changed: 51 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,58 @@ ImageKit iOS Pod allows you to use real-time [image resizing](https://docs.image
3232
## Installation
3333

3434
### Requirements
35-
The library requires Swift 4.0 or above.
35+
The library requires Swift 6.0 and minimum iOS version for deployment be 13.0 or above.
3636

37-
#### CocoaPods
37+
### Swift Package Manager
38+
39+
You can integrate ImageKit into your iOS project using the Swift Package Manager (SPM).
40+
41+
After completing the Swift Package setup in your project, you can add ImageKit in one of the following ways:
42+
43+
#### Using Xcode
44+
45+
Open your project in Xcode, then go to File → Add Packages…
46+
47+
```
48+
https://github.com/imagekit-developer/imagekit-ios.git
49+
```
50+
51+
Select the Up to Next Major version rule, starting from version 3.1.0, and add the package to your app target’s Package Dependencies list.
52+
53+
#### Using `Package.swift`
54+
55+
If you prefer managing dependencies manually, add ImageKit to the dependencies array in your `Package.swift` file:
56+
57+
```swift
58+
// swift-tools-version: 6.0
59+
import PackageDescription
60+
61+
let package = Package(
62+
name: "Example",
63+
platforms: [
64+
.iOS(.v13)
65+
],
66+
dependencies: [
67+
.package(url: "https://github.com/imagekit-developer/imagekit-ios.git", .upToNextMajor(from: "3.1.0"))
68+
],
69+
targets: [
70+
.target(
71+
name: "Example",
72+
dependencies: [
73+
"ImageKitIO"
74+
]
75+
)
76+
]
77+
)
78+
```
79+
80+
Once added, you can import ImageKitIO into your Swift files:
81+
82+
```
83+
import ImageKitIO
84+
```
85+
86+
### CocoaPods
3887

3988
You can use CocoaPods to install ImageKit by adding it to your Podfile:
4089

0 commit comments

Comments
 (0)