Skip to content

Commit ed92eb0

Browse files
committed
Bump to Swift 5.0
1 parent 8dd0c81 commit ed92eb0

File tree

4 files changed

+21
-19
lines changed

4 files changed

+21
-19
lines changed

Diff for: .swift-version

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
4.2
1+
5.0

Diff for: Example/SwiftCronExample.xcodeproj/project.pbxproj

+12-11
Original file line numberDiff line numberDiff line change
@@ -263,6 +263,7 @@
263263
developmentRegion = English;
264264
hasScannedForEncodings = 0;
265265
knownRegions = (
266+
English,
266267
en,
267268
Base,
268269
);
@@ -304,7 +305,7 @@
304305
files = (
305306
);
306307
inputPaths = (
307-
"${SRCROOT}/Pods/Target Support Files/Pods-SwiftCronExample/Pods-SwiftCronExample-frameworks.sh",
308+
"${PODS_ROOT}/Target Support Files/Pods-SwiftCronExample/Pods-SwiftCronExample-frameworks.sh",
308309
"${BUILT_PRODUCTS_DIR}/SwiftCron/SwiftCron.framework",
309310
);
310311
name = "[CP] Embed Pods Frameworks";
@@ -313,7 +314,7 @@
313314
);
314315
runOnlyForDeploymentPostprocessing = 0;
315316
shellPath = /bin/sh;
316-
shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-SwiftCronExample/Pods-SwiftCronExample-frameworks.sh\"\n";
317+
shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-SwiftCronExample/Pods-SwiftCronExample-frameworks.sh\"\n";
317318
showEnvVarsInLog = 0;
318319
};
319320
5C3A63B070FA8E0262619C5B /* [CP] Check Pods Manifest.lock */ = {
@@ -346,7 +347,7 @@
346347
);
347348
runOnlyForDeploymentPostprocessing = 0;
348349
shellPath = /bin/sh;
349-
shellScript = "\"${PODS_ROOT}/SwiftLint/swiftlint\"";
350+
shellScript = "\"${PODS_ROOT}/SwiftLint/swiftlint\"\n";
350351
};
351352
E87025957E0569C2E0F11DA7 /* [CP] Check Pods Manifest.lock */ = {
352353
isa = PBXShellScriptBuildPhase;
@@ -372,7 +373,7 @@
372373
files = (
373374
);
374375
inputPaths = (
375-
"${SRCROOT}/Pods/Target Support Files/Pods-SwiftCronExampleTests/Pods-SwiftCronExampleTests-frameworks.sh",
376+
"${PODS_ROOT}/Target Support Files/Pods-SwiftCronExampleTests/Pods-SwiftCronExampleTests-frameworks.sh",
376377
"${BUILT_PRODUCTS_DIR}/SwiftCron/SwiftCron.framework",
377378
);
378379
name = "[CP] Embed Pods Frameworks";
@@ -381,7 +382,7 @@
381382
);
382383
runOnlyForDeploymentPostprocessing = 0;
383384
shellPath = /bin/sh;
384-
shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-SwiftCronExampleTests/Pods-SwiftCronExampleTests-frameworks.sh\"\n";
385+
shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-SwiftCronExampleTests/Pods-SwiftCronExampleTests-frameworks.sh\"\n";
385386
showEnvVarsInLog = 0;
386387
};
387388
/* End PBXShellScriptBuildPhase section */
@@ -498,7 +499,7 @@
498499
ONLY_ACTIVE_ARCH = YES;
499500
SDKROOT = iphoneos;
500501
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
501-
SWIFT_VERSION = 4.2;
502+
SWIFT_VERSION = 5.0;
502503
};
503504
name = Debug;
504505
};
@@ -547,7 +548,7 @@
547548
MTL_ENABLE_DEBUG_INFO = NO;
548549
SDKROOT = iphoneos;
549550
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
550-
SWIFT_VERSION = 4.2;
551+
SWIFT_VERSION = 5.0;
551552
VALIDATE_PRODUCT = YES;
552553
};
553554
name = Release;
@@ -563,7 +564,7 @@
563564
PRODUCT_BUNDLE_IDENTIFIER = com.Rush42.SwiftCronExample;
564565
PRODUCT_NAME = "$(TARGET_NAME)";
565566
SWIFT_SWIFT3_OBJC_INFERENCE = Off;
566-
SWIFT_VERSION = 4.2;
567+
SWIFT_VERSION = 5.0;
567568
};
568569
name = Debug;
569570
};
@@ -578,7 +579,7 @@
578579
PRODUCT_BUNDLE_IDENTIFIER = com.Rush42.SwiftCronExample;
579580
PRODUCT_NAME = "$(TARGET_NAME)";
580581
SWIFT_SWIFT3_OBJC_INFERENCE = Off;
581-
SWIFT_VERSION = 4.2;
582+
SWIFT_VERSION = 5.0;
582583
};
583584
name = Release;
584585
};
@@ -596,7 +597,7 @@
596597
SWIFT_OBJC_BRIDGING_HEADER = "SwiftCronExampleTests/SwiftCronExampleTests-Bridging-Header.h";
597598
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
598599
SWIFT_SWIFT3_OBJC_INFERENCE = Off;
599-
SWIFT_VERSION = 4.2;
600+
SWIFT_VERSION = 5.0;
600601
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/SwiftCronExample.app/SwiftCronExample";
601602
};
602603
name = Debug;
@@ -614,7 +615,7 @@
614615
PRODUCT_NAME = "$(TARGET_NAME)";
615616
SWIFT_OBJC_BRIDGING_HEADER = "SwiftCronExampleTests/SwiftCronExampleTests-Bridging-Header.h";
616617
SWIFT_SWIFT3_OBJC_INFERENCE = Off;
617-
SWIFT_VERSION = 4.2;
618+
SWIFT_VERSION = 5.0;
618619
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/SwiftCronExample.app/SwiftCronExample";
619620
};
620621
name = Release;

Diff for: Sources/NSDateFormatter+Extensions.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ extension DateFormatter {
7777
// Sunday will be first. Make it last
7878
let sunday = "Sunday"
7979
if daysOfWeekArray.contains(sunday) {
80-
daysOfWeekArray.remove(at: daysOfWeekArray.index(of: sunday)!)
80+
daysOfWeekArray.remove(at: daysOfWeekArray.firstIndex(of: sunday)!)
8181
daysOfWeekArray.append(sunday)
8282
}
8383

Diff for: SwiftCron.xcodeproj/project.pbxproj

+7-6
Original file line numberDiff line numberDiff line change
@@ -155,17 +155,18 @@
155155
TargetAttributes = {
156156
9577E8F61E7396D4007854EE = {
157157
CreatedOnToolsVersion = 8.2.1;
158-
LastSwiftMigration = 1000;
158+
LastSwiftMigration = 1100;
159159
ProvisioningStyle = Automatic;
160160
};
161161
};
162162
};
163163
buildConfigurationList = 9577E8F11E7396D4007854EE /* Build configuration list for PBXProject "SwiftCron" */;
164164
compatibilityVersion = "Xcode 3.2";
165-
developmentRegion = English;
165+
developmentRegion = en;
166166
hasScannedForEncodings = 0;
167167
knownRegions = (
168168
en,
169+
Base,
169170
);
170171
mainGroup = 9577E8ED1E7396D4007854EE;
171172
productRefGroup = 9577E8F81E7396D4007854EE /* Products */;
@@ -271,7 +272,7 @@
271272
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
272273
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
273274
SWIFT_SWIFT3_OBJC_INFERENCE = Off;
274-
SWIFT_VERSION = 4.2;
275+
SWIFT_VERSION = 5.0;
275276
TARGETED_DEVICE_FAMILY = "1,2";
276277
VERSIONING_SYSTEM = "apple-generic";
277278
VERSION_INFO_PREFIX = "";
@@ -326,7 +327,7 @@
326327
SDKROOT = iphoneos;
327328
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
328329
SWIFT_SWIFT3_OBJC_INFERENCE = Off;
329-
SWIFT_VERSION = 4.2;
330+
SWIFT_VERSION = 5.0;
330331
TARGETED_DEVICE_FAMILY = "1,2";
331332
VALIDATE_PRODUCT = YES;
332333
VERSIONING_SYSTEM = "apple-generic";
@@ -351,7 +352,7 @@
351352
SKIP_INSTALL = YES;
352353
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
353354
SWIFT_SWIFT3_OBJC_INFERENCE = Off;
354-
SWIFT_VERSION = 4.2;
355+
SWIFT_VERSION = 5.0;
355356
};
356357
name = Debug;
357358
};
@@ -371,7 +372,7 @@
371372
PRODUCT_NAME = "$(TARGET_NAME)";
372373
SKIP_INSTALL = YES;
373374
SWIFT_SWIFT3_OBJC_INFERENCE = Off;
374-
SWIFT_VERSION = 4.2;
375+
SWIFT_VERSION = 5.0;
375376
};
376377
name = Release;
377378
};

0 commit comments

Comments
 (0)