forked from cpisciotta/xcbeautify
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Package.swift
78 lines (76 loc) · 2.83 KB
/
Package.swift
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
// swift-tools-version:5.9
import PackageDescription
let package = Package(
name: "xcbeautify",
products: [
.executable(name: "xcbeautify", targets: ["xcbeautify"]),
.library(name: "XcbeautifyLib", targets: ["XcbeautifyLib"]),
],
dependencies: [
.package(
url: "https://github.com/apple/swift-argument-parser.git",
.upToNextMinor(from: "1.5.0")
),
.package(
url: "https://github.com/getGuaka/Colorizer.git",
.upToNextMinor(from: "0.2.1")
),
.package(
url: "https://github.com/MaxDesiatov/XMLCoder.git",
.upToNextMinor(from: "0.17.1")
),
],
targets: [
.executableTarget(
name: "xcbeautify",
dependencies: [
"XcbeautifyLib",
.product(name: "ArgumentParser", package: "swift-argument-parser"),
]
),
.target(
name: "XcbeautifyLib",
dependencies: [
"Colorizer",
"XMLCoder",
]
),
.testTarget(
name: "XcbeautifyLibTests",
dependencies: ["XcbeautifyLib"],
resources: [
.copy("ParsingTests/clean_build_xcode_15_1.txt"),
.copy("ParsingTests/large_xcodebuild_log.txt"),
]
),
]
)
for target in package.targets {
var settings = target.swiftSettings ?? []
settings.append(
contentsOf: [
// TODO: Enable `complete` Strict Concurrency
// Currently, it's `targeted` since `XMLCoder` surfaces warnings.
.enableExperimentalFeature("StrictConcurrency=targeted"),
.enableUpcomingFeature("BareSlashRegexLiterals"),
.enableUpcomingFeature("ConciseMagicFile"),
.enableUpcomingFeature("DeprecateApplicationMain"),
.enableUpcomingFeature("DisableOutwardActorInference"),
.enableUpcomingFeature("DynamicActorIsolation"),
.enableUpcomingFeature("ExistentialAny"),
.enableUpcomingFeature("ForwardTrailingClosures"),
.enableUpcomingFeature("FullTypedThrows"),
.enableUpcomingFeature("GlobalActorIsolatedTypesUsability"),
// TODO: Enable GlobalConcurrency
// Currently, it's disabled since `XMLCoder` surfaces warnings.
// .enableUpcomingFeature("GlobalConcurrency"),
.enableUpcomingFeature("ImplicitOpenExistentials"),
.enableUpcomingFeature("ImportObjcForwardDeclarations"),
.enableUpcomingFeature("InferSendableFromCaptures"),
.enableUpcomingFeature("InternalImportsByDefault"),
.enableUpcomingFeature("IsolatedDefaultValues"),
.enableUpcomingFeature("RegionBasedIsolation"),
]
)
target.swiftSettings = settings
}