Skip to content

Commit a441576

Browse files
mikegerMichael Gerasymenko
andauthored
Update XcodeProj, fix compatibility issue (#32)
* Update XcodeProj, fix compatibility issue * Fix compilation on older Xcode * Use Swift 5.10.1 on Linux --------- Co-authored-by: Michael Gerasymenko <michael.gerasymenko@tamara.co>
1 parent bf995f5 commit a441576

File tree

5 files changed

+15
-4
lines changed

5 files changed

+15
-4
lines changed

.github/workflows/test.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,11 @@ jobs:
1818
runs-on: ubuntu-22.04
1919
steps:
2020
- uses: actions/checkout@v3
21+
- uses: swift-actions/setup-swift@v2
22+
with:
23+
swift-version: "5.10.1"
24+
- name: Get swift version
25+
run: swift --version # Swift 5.1.0
2126
- name: Prepare Git
2227
run: git config --global user.email "test@example.com" && git config --global user.name "Test User"
2328
- name: Run tests

Package.resolved

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

Package.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ let package = Package(
6969
],
7070
products: products,
7171
dependencies: [
72-
.package(url: "https://github.com/tuist/XcodeProj.git", .upToNextMajor(from: "8.20.0")),
72+
.package(url: "https://github.com/tuist/XcodeProj.git", .upToNextMajor(from: "8.24.1")),
7373
.package(url: "https://github.com/apple/swift-argument-parser.git", .upToNextMajor(from: "1.2.0")),
7474
.package(url: "https://github.com/kylef/PathKit.git", .upToNextMinor(from: "1.0.0")),
7575
.package(url: "https://github.com/onevcat/Rainbow", .upToNextMajor(from: "4.0.0")),

Plugins/SelectiveTestingPlugin/SelectiveTestingPlugin.swift

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,12 @@ struct SelectiveTestingPlugin: CommandPlugin {
5656
}
5757
#endif
5858

59+
#if compiler(>=6)
5960
extension String: @retroactive LocalizedError {
6061
public var errorDescription: String? { return self }
6162
}
63+
#else
64+
extension String: LocalizedError {
65+
public var errorDescription: String? { return self }
66+
}
67+
#endif

Sources/DependencyCalculator/DependencyGraph.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,7 @@ extension WorkspaceInfo {
273273
}
274274

275275
// Package dependencies
276-
for packageDependency in target.packageProductDependencies {
276+
for packageDependency in (target.packageProductDependencies ?? []) {
277277
let package = packageDependency.productName
278278
guard let packageMetadata = packagesByName[package] else {
279279
Logger.warning("Package \(package) not found")

0 commit comments

Comments
 (0)