mirror of
https://github.com/swift-server/swift-aws-lambda-runtime.git
synced 2026-06-02 07:27:33 +00:00
ddad9b9bee
## Summary Examples now default to the published `swift-aws-lambda-runtime` package from GitHub, so they work out of the box when cloned standalone (as described in the READMEs). CI scripts swap the dependency to the local path (`../..`) before building, ensuring we still test against the current branch. ### Changes - **`Examples/APIGatewayV2/Package.swift`** — Default to remote URL, local path is commented out with clear instructions. - **`.github/workflows/scripts/use-local-deps.sh`** (new) — Shared script that rewrites Package.swift to use the local dependency. - **`integration_tests.sh`**, **`check-archive-plugin.sh`**, **`check-link-foundation.sh`** — Source `use-local-deps.sh` before building.
30 lines
962 B
Swift
30 lines
962 B
Swift
// swift-tools-version:6.2
|
|
|
|
import PackageDescription
|
|
|
|
let package = Package(
|
|
name: "MultiSourceAPI",
|
|
platforms: [.macOS(.v15)],
|
|
products: [
|
|
.executable(name: "MultiSourceAPI", targets: ["MultiSourceAPI"])
|
|
],
|
|
dependencies: [
|
|
// For local development, uncomment the line below and comment the remote dependency:
|
|
// .package(name: "swift-aws-lambda-runtime", path: "../.."),
|
|
|
|
.package(url: "https://github.com/awslabs/swift-aws-lambda-runtime.git", from: "2.9.0"),
|
|
|
|
.package(url: "https://github.com/awslabs/swift-aws-lambda-events.git", from: "1.0.0"),
|
|
],
|
|
targets: [
|
|
.executableTarget(
|
|
name: "MultiSourceAPI",
|
|
dependencies: [
|
|
.product(name: "AWSLambdaRuntime", package: "swift-aws-lambda-runtime"),
|
|
.product(name: "AWSLambdaEvents", package: "swift-aws-lambda-events"),
|
|
],
|
|
path: "Sources"
|
|
)
|
|
]
|
|
)
|