-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathPackage.swift
94 lines (90 loc) · 3.07 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
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
// swift-tools-version:6.0
import PackageDescription
let package = Package(
name: "portfolio",
platforms: [
.macOS(.v13),
],
products: [
.library(name: "ActivityClient", targets: ["ActivityClient"]),
.library(name: "Models", targets: ["Models"]),
.library(name: "Routes", targets: ["Routes"]),
.library(name: "Pages", targets: ["Pages"]),
.executable(name: "App", targets: ["App"]),
],
dependencies: [
.package(url: "https://github.com/apple/swift-argument-parser.git", from: "1.4.0"),
.package(url: "https://github.com/hummingbird-project/hummingbird.git", exact: "2.5.0"),
.package(url: "https://github.com/sliemeobn/elementary.git", exact: "0.4.3"),
.package(url: "https://github.com/pointfreeco/swift-url-routing.git", exact: "0.6.2"),
.package(url: "https://github.com/pointfreeco/swift-dependencies.git", exact: "1.6.2"),
.package(url: "https://github.com/errorerrorerror/swift-cascadia", revision: "a13dfd0a3818c8f9368bbd4aeb3c6607f68838bd"),
.package(url: "https://github.com/swiftlang/swift-markdown.git", revision: "e62a44fd1f2764ba8807db3b6f257627449bbb8c")
],
targets: [
.target(
name: "Models",
dependencies: [
.product(name: "Dependencies", package: "swift-dependencies"),
]
),
.target(
name: "ActivityClient",
dependencies: [
.product(name: "Dependencies", package: "swift-dependencies"),
.product(name: "DependenciesMacros", package: "swift-dependencies"),
]
),
.target(
name: "Routes",
dependencies: [
"Models",
"ActivityClient",
.product(name: "Dependencies", package: "swift-dependencies"),
.product(name: "URLRouting", package: "swift-url-routing"),
.product(name: "Hummingbird", package: "hummingbird"),
.product(name: "HummingbirdRouter", package: "hummingbird"),
]
),
.target(
name: "Pages",
dependencies: [
"Models",
"ActivityClient",
.product(name: "Dependencies", package: "swift-dependencies"),
.product(name: "Elementary", package: "elementary"),
.product(name: "Hummingbird", package: "hummingbird"),
.product(name: "Cascadia", package: "swift-cascadia"),
.product(name: "Markdown", package: "swift-markdown")
]
),
/// Executable
.executableTarget(
name: "App",
dependencies: [
"Models",
"Routes",
"Pages",
"ActivityClient",
.product(name: "Dependencies", package: "swift-dependencies"),
.product(name: "Hummingbird", package: "hummingbird"),
.product(name: "HummingbirdRouter", package: "hummingbird"),
.product(name: "ArgumentParser", package: "swift-argument-parser")
],
resources: [.embedInCode("Resources")]
),
],
swiftLanguageModes: [.v6]
)
package.targets
.filter { $0.type != .binary }
.forEach {
$0.swiftSettings = [
.unsafeFlags([
"-Xfrontend",
"-warn-long-function-bodies=100",
"-Xfrontend",
"-warn-long-expression-type-checking=100"
])
]
}