4.3.12 #65
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: Build SSTool | |
| on: | |
| push: | |
| branches: [ "master" ] | |
| paths: | |
| - 'SpessaSharp/**' | |
| - 'SSTool/**' | |
| workflow_dispatch: | |
| jobs: | |
| build: | |
| strategy: | |
| matrix: | |
| include: | |
| - os: ubuntu-latest | |
| script: .github/scripts/build_sstool_linux-64.sh | |
| artifact-name: linux-appimage | |
| - os: windows-latest | |
| script: .github\scripts\build_sstool_win-64.bat | |
| artifact-name: windows-exe | |
| runs-on: ${{ matrix.os }} | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v5 | |
| with: | |
| dotnet-version: '10.0.x' | |
| - name: Make script executable (Linux) | |
| if: runner.os == 'Linux' | |
| run: chmod +x ${{ matrix.script }} | |
| - name: Run Build Script | |
| working-directory: ./SSTool | |
| # Use the absolute workspace path so it always finds the script | |
| run: | | |
| if [ "${{ runner.os }}" == "Linux" ]; then | |
| "$GITHUB_WORKSPACE/.github/scripts/build_sstool_linux-64.sh" | |
| else | |
| "$(echo $GITHUB_WORKSPACE | sed 's/\//\\/g')\.github\scripts\build_sstool_win-64.bat" | |
| fi | |
| shell: bash # Use bash for both to keep the logic consistent | |
| - name: Upload Artifact | |
| uses: actions/upload-artifact@v6 | |
| with: | |
| name: ${{ matrix.artifact-name }} | |
| path: dist/ # Scripts should move final files here | |
| - name: Create Release | |
| uses: softprops/action-gh-release@v2 | |
| if: startsWith(github.ref, 'refs/tags/') # Only runs if you push a tag like v1.0 | |
| with: | |
| files: | | |
| dist/ss | |
| dist/ss.exe | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |