55 lines
1.6 KiB
Swift
55 lines
1.6 KiB
Swift
// swift-tools-version:5.7
|
|
|
|
import PackageDescription
|
|
|
|
let package = Package(
|
|
name: "swiftui-introspect",
|
|
platforms: [
|
|
.iOS(.v13),
|
|
.macOS(.v10_15),
|
|
.tvOS(.v13),
|
|
],
|
|
products: [
|
|
// legacy library
|
|
.library(name: "Introspect", targets: ["Introspect"]),
|
|
.library(name: "Introspect-Static", type: .static, targets: ["Introspect"]),
|
|
.library(name: "Introspect-Dynamic", type: .dynamic, targets: ["Introspect"]),
|
|
|
|
// new experimental library
|
|
.library(name: "SwiftUIIntrospect", targets: ["SwiftUIIntrospect"]),
|
|
.library(name: "SwiftUIIntrospect-Static", type: .static, targets: ["SwiftUIIntrospect"]),
|
|
.library(name: "SwiftUIIntrospect-Dynamic", type: .dynamic, targets: ["SwiftUIIntrospect"]),
|
|
|
|
// infrastructure
|
|
.executable(name: "generate-docs", targets: ["GenerateDocs"]),
|
|
],
|
|
targets: [
|
|
.target(
|
|
name: "Introspect",
|
|
path: "Introspect"
|
|
),
|
|
.testTarget(
|
|
name: "IntrospectTests",
|
|
dependencies: ["Introspect"],
|
|
path: "IntrospectTests"
|
|
),
|
|
|
|
.target(
|
|
name: "SwiftUIIntrospect",
|
|
path: "Sources"
|
|
),
|
|
|
|
.executableTarget(
|
|
name: "GenerateDocs",
|
|
dependencies: [
|
|
.product(name: "SwiftSyntax", package: "swift-syntax"),
|
|
],
|
|
path: "Scripts/GenerateDocs"
|
|
),
|
|
]
|
|
)
|
|
|
|
package.dependencies += [
|
|
.package(url: "https://github.com/apple/swift-syntax", from: "508.0.1"),
|
|
]
|