Repository navigation
Expand file tree
/
Copy pathPackage.swift
More file actions
74 lines (70 loc) · 3.5 KB
/
Copy pathPackage.swift
File metadata and controls
74 lines (70 loc) · 3.5 KB
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
// swift-tools-version: 6.0
import PackageDescription
// HashNotch is deliberately split into small, independent modules.
//
// HashNotchKit the core: notch window, HUD layout, and the NotchFeature
// plugin contract. It knows nothing about any concrete feature.
// Feature* one self-contained module per feature. Each depends only on
// HashNotchKit — never on another feature.
// HashNotch the executable. The ONLY place features are wired together
// (see Sources/HashNotch/FeatureManifest.swift).
//
// To add a feature: add a `Feature<Name>` target below, depend on it from the
// `HashNotch` target, and register it in FeatureManifest. Nothing in
// HashNotchKit ever needs to change.
let package = Package(
name: "HashNotch",
platforms: [.macOS(.v12)],
products: [
.executable(name: "HashNotch", targets: ["HashNotch"])
],
targets: [
.target(name: "HashNotchKit"),
.target(name: "FeatureNetwork", dependencies: ["HashNotchKit"]),
.target(name: "FeatureBattery", dependencies: ["HashNotchKit"]),
.target(name: "FeatureThermal", dependencies: ["HashNotchKit"]),
.target(name: "FeatureTokens", dependencies: ["HashNotchKit"]),
.target(name: "FeatureMedia", dependencies: ["HashNotchKit"]),
.target(name: "FeatureActivities", dependencies: ["HashNotchKit"]),
.target(name: "FeatureTimer", dependencies: ["HashNotchKit"]),
.target(name: "FeatureDownloads", dependencies: ["HashNotchKit"]),
.target(name: "FeatureAway", dependencies: ["HashNotchKit"]),
.target(name: "FeatureFocus", dependencies: ["HashNotchKit"]),
.target(name: "FeatureAirPods", dependencies: ["HashNotchKit"]),
.target(name: "FeatureCall", dependencies: ["HashNotchKit"]),
.target(name: "FeatureStorage", dependencies: ["HashNotchKit"]),
.target(name: "FeatureCPU", dependencies: ["HashNotchKit"]),
.target(name: "FeatureGPU", dependencies: ["HashNotchKit"]),
.target(name: "FeatureMemory", dependencies: ["HashNotchKit"]),
.target(name: "FeaturePower", dependencies: ["HashNotchKit"]),
.executableTarget(
name: "HashNotch",
dependencies: [
"HashNotchKit",
"FeatureNetwork",
"FeatureBattery",
"FeatureThermal",
"FeatureTokens",
"FeatureMedia",
"FeatureActivities",
"FeatureTimer",
"FeatureDownloads", "FeatureAway", "FeatureFocus",
"FeatureAirPods", "FeatureCall",
"FeatureStorage",
"FeatureCPU",
"FeatureGPU",
"FeatureMemory",
"FeaturePower",
]
),
// Lightweight, framework-free checks so the core can be verified with
// `swift run HashNotchChecks` even on a machine that only has the
// Command Line Tools (no XCTest/Swift Testing). Swap for a proper
// .testTarget once full Xcode is available.
.executableTarget(
name: "HashNotchChecks",
dependencies: ["HashNotchKit", "FeatureMedia", "FeatureActivities", "FeatureTokens", "FeatureBattery", "FeatureDownloads", "FeatureAway", "FeatureFocus", "FeatureAirPods", "FeatureCall", "FeatureNetwork", "FeatureStorage", "FeatureThermal", "FeatureCPU", "FeatureGPU", "FeatureMemory", "FeatureTimer", "FeaturePower"]
),
],
swiftLanguageModes: [.v5]
)