From b2d010270224189d1b85652a51ebf049fe83f5e9 Mon Sep 17 00:00:00 2001 From: MaraMincho <103064352+MaraMincho@users.noreply.github.com> Date: Sat, 28 Dec 2024 17:23:03 +0900 Subject: [PATCH] feat: update github action --- .github/workflows/ios.yml | 36 ++++++++++++++++++++++++------------ 1 file changed, 24 insertions(+), 12 deletions(-) diff --git a/.github/workflows/ios.yml b/.github/workflows/ios.yml index b5ec12b..98f475a 100644 --- a/.github/workflows/ios.yml +++ b/.github/workflows/ios.yml @@ -1,4 +1,4 @@ -name: Swift +name: Swift CI on: push: @@ -10,20 +10,32 @@ on: jobs: build: - name: Swift ${{ matrix.swift }} on ${{ matrix.os }} strategy: matrix: - os: [ubuntu-latest, macos-latest] - swift: ["6", "5"] + include: + - os: ubuntu-latest + swift: "5" + - os: macos-latest + swift: "5" runs-on: ${{ matrix.os }} + steps: - - uses: swift-actions/setup-swift@v2.1.0 + - uses: actions/checkout@v4 + + - name: Set up Swift + if: ${{ matrix.os == 'macos-latest' }} + run: sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer + + - name: Install Swift + uses: swift-actions/setup-swift@v2.1.0 with: swift-version: ${{ matrix.swift }} - - name: Get swift version - run: swift --version # Swift 5.10.1 - - uses: actions/checkout@v4 - - name: Build - run: swift build --package-path SwiftErrorArchiver/ - - name: Run tests - run: swift test --package-path SwiftErrorArchiver/ \ No newline at end of file + + - name: Check Swift version + run: swift --version + + - name: Build Project + run: swift build --package-path SwiftErrorArchiver/ + + - name: Run Tests + run: swift test --package-path SwiftErrorArchiver/