diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index f2d9a20..0c4c801 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -39,7 +39,7 @@ jobs: - uses: swift-actions/setup-swift@v1.17.0 id: swift-setup with: - swift-version: '5.6' + swift-version: '5.7' - name: Read OS Version uses: sersoft-gmbh/os-version-action@v2.0.0 id: os-version @@ -59,7 +59,7 @@ jobs: needs: - release-context - spm-context - runs-on: macos-11 + runs-on: macos-12 strategy: matrix: target: ${{fromJson(needs.spm-context.outputs.package-dump).products.*.targets.*}} @@ -67,7 +67,7 @@ jobs: - uses: swift-actions/setup-swift@v1.17.0 id: swift-setup with: - swift-version: '5.6' + swift-version: '5.7' - name: Read OS Version uses: sersoft-gmbh/os-version-action@v2.0.0 id: os-version diff --git a/.github/workflows/swift-test.yml b/.github/workflows/swift-test.yml index b1339c6..a3cac3a 100644 --- a/.github/workflows/swift-test.yml +++ b/.github/workflows/swift-test.yml @@ -10,8 +10,25 @@ jobs: test-spm: strategy: matrix: - os: [ macos-11, ubuntu-20.04 ] - swift-version: [ 5.5, 5.6 ] + os: [ macos-11 ] + swift-version: [ '' ] + xcode-version: [ '^13.0' ] + include: + - os: macos-12 + swift-version: '' + xcode-version: '^14.0' + - os: ubuntu-20.04 + swift-version: 5.5 + xcode-version: '' + - os: ubuntu-20.04 + swift-version: 5.6 + xcode-version: '' + - os: ubuntu-20.04 + swift-version: 5.7 + xcode-version: '' + - os: ubuntu-22.04 + swift-version: 5.7 + xcode-version: '' runs-on: ${{matrix.os}} @@ -19,7 +36,7 @@ jobs: - if: runner.os == 'macOS' uses: maxim-lobanov/setup-xcode@v1.4.1 with: - xcode-version: ^13.0 + xcode-version: ${{matrix.xcode-version}} - name: Install Swift if: runner.os == 'Linux' uses: sersoft-gmbh/swifty-linux-action@v2.1.0 @@ -52,44 +69,32 @@ jobs: fail_ci_if_error: true test-xcode: - runs-on: macos-11 + runs-on: macos-12 strategy: matrix: - action: [ test ] destination: - platform=macOS - - platform=iOS Simulator,OS=latest,name=iPhone 11 Pro - - platform=iOS Simulator,OS=latest,name=iPad Pro (11-inch) (2nd generation) - - platform=tvOS Simulator,OS=latest,name=Apple TV 4K - # parallel-testing-enabled: [true] - # enable-code-coverage: [true] - # Watch currently doesn't work because there's no XCTest on watchOS - # include: - # - action: build - # destination: platform=watchOS Simulator,OS=latest,name=Apple Watch Series 6 - 44mm - # parallel-testing-enabled: false - # enable-code-coverage: false + - platform=iOS Simulator,OS=latest,name=iPhone 13 Pro + - platform=iOS Simulator,OS=latest,name=iPad Pro (11-inch) (3rd generation) + - platform=tvOS Simulator,OS=latest,name=Apple TV 4K (2nd generation) + - platform=watchOS Simulator,OS=latest,name=Apple Watch Series 7 (45mm) steps: - uses: maxim-lobanov/setup-xcode@v1.4.1 with: - xcode-version: ^13.0 + xcode-version: ^14.0 - uses: actions/checkout@v3.0.2 - uses: sersoft-gmbh/xcodebuild-action@v2.0.0 with: spm-package: './' scheme: app-information destination: ${{matrix.destination}} - action: ${{matrix.action}} + action: test parallel-testing-enabled: true enable-code-coverage: true - # parallel-testing-enabled: ${{matrix.parallel-testing-enabled}} - # enable-code-coverage: ${{matrix.enable-code-coverage}} - uses: sersoft-gmbh/swift-coverage-action@v3.0.0 id: coverage-files - if: matrix.action == 'test' - uses: codecov/codecov-action@v3.1.0 with: token: ${{secrets.CODECOV_TOKEN}} files: ${{join(fromJSON(steps.coverage-files.outputs.files), ',')}} fail_ci_if_error: true - if: matrix.action == 'test' diff --git a/Package.swift b/Package.swift index 1a04eea..2b45849 100644 --- a/Package.swift +++ b/Package.swift @@ -1,4 +1,4 @@ -// swift-tools-version:5.6 +// swift-tools-version:5.7 // The swift-tools-version declares the minimum version of Swift required to build this package. import PackageDescription diff --git a/Package@swift-5.6.swift b/Package@swift-5.6.swift new file mode 100644 index 0000000..1a04eea --- /dev/null +++ b/Package@swift-5.6.swift @@ -0,0 +1,27 @@ +// swift-tools-version:5.6 +// The swift-tools-version declares the minimum version of Swift required to build this package. + +import PackageDescription +import Foundation + +let package = Package( + name: "app-information", + products: [ + // Products define the executables and libraries a package produces, and make them visible to other packages. + .library( + name: "AppInformation", + targets: ["AppInformation"]), + ], + targets: [ + // Targets are the basic building blocks of a package. A target can define a module or a test suite. + // Targets can depend on other targets in this package, and on products in packages this package depends on. + .target(name: "AppInformation"), + .testTarget( + name: "AppInformationTests", + dependencies: ["AppInformation"]), + ] +) + +if ProcessInfo.processInfo.environment["ENABLE_DOCC_SUPPORT"] == "1" { + package.dependencies.append(.package(url: "https://github.com/apple/swift-docc-plugin", from: "1.0.0")) +}