diff --git a/.github/matrix.json b/.github/matrix.json new file mode 100644 index 0000000..00b4329 --- /dev/null +++ b/.github/matrix.json @@ -0,0 +1,7 @@ +{ + "xcode_version": [ + "13.2.1", + "13.4.1", + "14.2" + ] +} \ No newline at end of file diff --git a/.github/workflows/demo.yml b/.github/workflows/demo.yml index 79e48c1..989c5dc 100644 --- a/.github/workflows/demo.yml +++ b/.github/workflows/demo.yml @@ -17,8 +17,8 @@ jobs: - uses: actions/checkout@v3 - id: extract-xcode-version run: | - latest_xcode_version=$(cat versions.json | jq -r '.xcode_version | max') - echo "::set-output name=latest_xcode_version::$latest_xcode_version" + latest_xcode_version=$(cat .github/matrix.json | jq -r '.xcode_version | max') + echo "latest_xcode_version=$latest_xcode_version" >> $GITHUB_OUTPUT test: name: Test needs: xcode-version @@ -37,7 +37,7 @@ jobs: id: test run: | platform=$(echo '${{ matrix.destination }}' | sed -E 's/platform=(.*)(,name=.*)/\1/g' | tr ' ' '_') - echo "::set-output name=platform::$platform" + echo "platform=$platform" >> $GITHUB_OUTPUT defaults write com.apple.dt.XCBuild EnableSwiftBuildSystemIntegration 1 cd DemoApp/MockUserDefaultsDemoLib xcrun xcodebuild \ diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index efb14ec..b4b6d8f 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -6,7 +6,7 @@ on: - '**.h' - '**.m' - '.github/workflows/test.yml' - - 'versions.json' + - '.github/matrix.json' concurrency: group: ${{ github.ref }} cancel-in-progress: true @@ -21,8 +21,8 @@ jobs: - uses: actions/checkout@v3 - id: set-matrix run: | - echo "::set-output name=matrix::$(cat versions.json | jq -c .)" - echo "::set-output name=latest-xcode-version::$(cat versions.json | jq -rc '.xcode_version | max')" + echo "matrix=$(cat .github/matrix.json | jq -c .)" >> $GITHUB_OUTPUT + echo "latest-xcode-version=$(cat .github/matrix.json | jq -rc '.xcode_version | max')" >> $GITHUB_OUTPUT xcodebuild: name: via xcodebuild needs: generate-matrix @@ -35,7 +35,7 @@ jobs: - 'platform=macOS,variant=Mac Catalyst' - 'platform=iOS Simulator,name=iPhone 11 Pro' - 'platform=tvOS Simulator,name=Apple TV' - - 'platform=watchOS Simulator,name=Apple Watch Series 4 - 40mm' + - 'platform=watchOS Simulator,name=Apple Watch Series 5 (40mm)' env: DEVELOPER_DIR: /Applications/Xcode_${{ needs.generate-matrix.outputs.latest-xcode-version }}.app/Contents/Developer steps: @@ -44,7 +44,7 @@ jobs: id: test run: | platform=$(echo '${{ matrix.destination }}' | sed -E 's/platform=(.*)(,name=.*)/\1/g' | tr ' ' '_') - echo "::set-output name=platform::$platform" + echo "platform=$platform" >> $GITHUB_OUTPUT defaults write com.apple.dt.XCBuild EnableSwiftBuildSystemIntegration 1 xcrun xcodebuild \ -enableCodeCoverage=YES \ diff --git a/versions.json b/versions.json deleted file mode 100644 index 638db62..0000000 --- a/versions.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "xcode_version": [ - "12.5.1", - "13.2.1" - ] -} \ No newline at end of file