-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathPackage.swift
More file actions
78 lines (76 loc) · 3.02 KB
/
Package.swift
File metadata and controls
78 lines (76 loc) · 3.02 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
75
76
77
78
// swift-tools-version: 5.10
// The swift-tools-version declares the minimum version of Swift required to build this package.
import PackageDescription
let package = Package(
name: "ExarotonAPI",
platforms: [
.macOS(.v10_15),
.iOS(.v13),
.visionOS(.v1),
.watchOS(.v6),
.tvOS(.v13),
],
products: [
// Products define the executables and libraries a package produces, making them visible to other packages.
.library(name: "ExarotonHTTP", targets: ["ExarotonHTTP"]),
.library(name: "ExarotonWebSocket", targets: ["ExarotonWebSocket"]),
],
dependencies: [
.package(url: "https://github.com/apple/swift-openapi-generator.git", from: "1.11.0"),
.package(url: "https://github.com/apple/swift-openapi-runtime.git", from: "1.11.0"),
.package(url: "https://github.com/apple/swift-openapi-urlsession.git", from: "1.2.0"),
.package(url: "https://github.com/apple/swift-http-types", from: "1.5.1"),
.package(url: "https://github.com/daltoniam/Starscream.git", from: "4.0.8"),
.package(url: "https://github.com/flight-school/anycodable.git", from: "0.6.7"),
.package(url: "https://github.com/apple/swift-log.git", from: "1.10.1"),
.package(url: "https://github.com/swiftlang/swift-testing.git", from: "6.2.4"),
],
targets: [
// Targets are the basic building blocks of a package, defining a module or a test suite.
// Targets can depend on other targets in this package and products from dependencies.
.target(
name: "ExarotonHTTP",
dependencies: [
.product(name: "OpenAPIRuntime", package: "swift-openapi-runtime"),
.product(name: "OpenAPIURLSession", package: "swift-openapi-urlsession"),
.product(name: "HTTPTypes", package: "swift-http-types"),
], plugins: [
.plugin(name: "OpenAPIGenerator", package: "swift-openapi-generator"),
]
),
.testTarget(
name: "ExarotonHTTPTests",
dependencies: [
"ExarotonHTTP",
.product(name: "Testing", package: "swift-testing")
]
),
.target(
name: "ExarotonWebSocket",
dependencies: [
.product(name: "Starscream", package: "starscream"),
.product(name: "AnyCodable", package: "AnyCodable"),
.product(name: "Logging", package: "swift-log"),
]
),
.testTarget(
name: "ExarotonWebSocketTests",
dependencies: [
"ExarotonWebSocket",
.product(name: "Testing", package: "swift-testing")
]
),
.executableTarget(
name: "HTTPUsageDemo",
dependencies: [
"ExarotonHTTP",
]
),
.executableTarget(
name: "WebSocketUsageDemo",
dependencies: [
"ExarotonWebSocket",
]
),
]
)