Moved the project files from the executable target to the library target.
This commit is contained in:
parent
02299f1cc2
commit
94e28a324b
47
Sources/Library/Resources/Files/Package
Normal file
47
Sources/Library/Resources/Files/Package
Normal file
@ -0,0 +1,47 @@
|
||||
// swift-tools-version:6.0
|
||||
|
||||
import PackageDescription
|
||||
|
||||
let package = Package(
|
||||
name: "{{HB_PACKAGE_NAME}}",
|
||||
platforms: [
|
||||
.macOS(.v10_15)
|
||||
],
|
||||
products: [
|
||||
.executable(name: "app", targets: ["App"]),
|
||||
.library(name: "AppInfrastructure", targets: ["AppInfrastructure"])
|
||||
],
|
||||
dependencies: [
|
||||
.package(url: "https://github.com/hummingbird-project/hummingbird.git", from: "2.0.0"),
|
||||
.package(url: "https://github.com/apple/swift-argument-parser.git", from: "1.3.0")
|
||||
],
|
||||
targets: [
|
||||
.executableTarget(
|
||||
name: "App",
|
||||
dependencies: [
|
||||
.byName(name: "AppInfrastructure"),
|
||||
.product(name: "ArgumentParser", package: "swift-argument-parser"),
|
||||
.product(name: "Hummingbird", package: "hummingbird")
|
||||
],
|
||||
path: "Sources/App"
|
||||
),
|
||||
.target(
|
||||
name: "AppInfrastructure",
|
||||
dependencies: [
|
||||
.product(name: "ArgumentParser", package: "swift-argument-parser"),
|
||||
.product(name: "Hummingbird", package: "hummingbird"),
|
||||
],
|
||||
path: "Sources/AppInfrastructure"
|
||||
),
|
||||
.testTarget(
|
||||
name: "AppTests",
|
||||
dependencies: [
|
||||
dependencies: [
|
||||
.byName(name: "AppInfrastructure"),
|
||||
.product(name: "HummingbirdTesting", package: "hummingbird")
|
||||
]
|
||||
],
|
||||
path: "Tests/App"
|
||||
)
|
||||
]
|
||||
)
|
Loading…
x
Reference in New Issue
Block a user