|
| 1 | +// swift-tools-version: {{ cookiecutter._swift_tools_version }} |
| 2 | +// The swift-tools-version declares the minimum version of Swift required to build this package. |
| 3 | + |
| 4 | +//===----------------------------------------------------------------------===// |
| 5 | +// |
| 6 | +// This source file is part of the AWS Lambda Swift |
| 7 | +// VSCode extension open source project. |
| 8 | +// |
| 9 | +// Copyright (c) 2024, the VSCode AWS Lambda Swift extension project authors. |
| 10 | +// Licensed under Apache License v2.0. |
| 11 | +// |
| 12 | +// See LICENSE.txt for license information |
| 13 | +// See CONTRIBUTORS.txt for the list of VSCode AWS Lambda Swift project authors |
| 14 | +// |
| 15 | +// SPDX-License-Identifier: Apache-2.0 |
| 16 | +// |
| 17 | +//===----------------------------------------------------------------------===// |
| 18 | + |
| 19 | +import PackageDescription |
| 20 | + |
| 21 | +let package = Package( |
| 22 | + name: "QuoteService", |
| 23 | + platforms: [ |
| 24 | + .macOS(.v13), .iOS(.v15), .tvOS(.v15), .watchOS(.v6), |
| 25 | + ], |
| 26 | + products: [ |
| 27 | + .executable(name: "QuoteService", targets: ["QuoteService"]), |
| 28 | + ], |
| 29 | + dependencies: [ |
| 30 | + .package(url: "https://github.com/apple/swift-openapi-generator.git", from: "1.0.0"), |
| 31 | + .package(url: "https://github.com/apple/swift-openapi-runtime.git", from: "1.0.0"), |
| 32 | + .package(url: "https://github.com/swift-server/swift-aws-lambda-runtime.git", from: "1.0.0-alpha.1"), |
| 33 | + .package(url: "https://github.com/swift-server/swift-aws-lambda-events.git", from: "0.2.0"), |
| 34 | + .package(url: "https://github.com/swift-server/swift-openapi-lambda.git", from: "0.1.1") |
| 35 | + ], |
| 36 | + targets: [ |
| 37 | + .executableTarget( |
| 38 | + name: "QuoteService", |
| 39 | + dependencies: [ |
| 40 | + .product(name: "OpenAPIRuntime",package: "swift-openapi-runtime"), |
| 41 | + .product(name: "AWSLambdaRuntime", package: "swift-aws-lambda-runtime"), |
| 42 | + .product(name: "AWSLambdaEvents", package: "swift-aws-lambda-events"), |
| 43 | + .product(name: "OpenAPILambda",package: "swift-openapi-lambda"), |
| 44 | + ], |
| 45 | + path: "Sources", |
| 46 | + resources: [ |
| 47 | + .copy("openapi.yaml"), |
| 48 | + .copy("openapi-generator-config.yaml") |
| 49 | + ], |
| 50 | + plugins: [ |
| 51 | + .plugin( |
| 52 | + name: "OpenAPIGenerator", |
| 53 | + package: "swift-openapi-generator" |
| 54 | + ) |
| 55 | + ] |
| 56 | + ) |
| 57 | + ] |
| 58 | +) |
0 commit comments