更新原有的CI/CD #7
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CD for Liii STEM on macOS arm64 | |
| on: | |
| workflow_dispatch: | |
| push: | |
| tags: | |
| - '*' | |
| jobs: | |
| macosbuild: | |
| strategy: | |
| matrix: | |
| os: [macos-13] | |
| arch: [arm64] | |
| runs-on: ${{ matrix.os }} | |
| timeout-minutes: 45 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 1 | |
| - name: Install dependencies | |
| run: | | |
| brew update | |
| brew install curl openssl libgit2 | |
| - name: Install Qt | |
| uses: jurplel/install-qt-action@v4 | |
| with: | |
| version: 6.5.3 | |
| target: 'desktop' | |
| cache: 'true' | |
| - uses: xmake-io/github-action-setup-xmake@v1 | |
| with: | |
| xmake-version: v2.8.7 | |
| actions-cache-folder: '.xmake-cache' | |
| - name: cache packages from xrepo | |
| uses: actions/cache@v4 | |
| with: | |
| path: | | |
| ~/.xmake/packages | |
| key: xrepo-${{ runner.os }}-${{ matrix.arch }}-${{ hashFiles('xmake-requires.lock') }} | |
| - name: xmake repo --update | |
| run: xmake repo --update | |
| - name: config | |
| run: xmake config -m release -a ${{ matrix.arch }} -vD --yes | |
| - name: build | |
| run: xmake build -vD --yes liii | |
| - name: install | |
| run: xmake install -vD liii | |
| - name: Generate Installer | |
| run: | | |
| xmake install -vD liii_packager | |
| - name: Upload | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: LiiiSTEM-macos-arm64-dmg | |
| path: build/LiiiSTEM-*.dmg | |
| - name: Release | |
| uses: softprops/action-gh-release@v1 | |
| if: startsWith(github.ref, 'refs/tags/') | |
| with: | |
| prerelease: true | |
| files: build/LiiiSTEM-*.dmg | |