v1.0.0 #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: Release | |
| on: | |
| release: | |
| types: [published] | |
| permissions: | |
| contents: write | |
| jobs: | |
| build: | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: ['windows-latest'] | |
| env: | |
| SPEC_FILE: 'yasumi.spec' | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: 3.11.x | |
| - name: Install Python dependencies | |
| run: | | |
| pip install -r requirements.txt | |
| working-directory: ./ | |
| - name: Install PyInstaller | |
| run: | | |
| pip install pyinstaller | |
| working-directory: ./ | |
| - name: Build executable | |
| run: | | |
| pyinstaller ${{ env.SPEC_FILE }} | |
| - name: Create Artifact (Windows) | |
| if: matrix.os == 'windows-latest' | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: windows-executables | |
| path: dist/ | |
| - name: Create Artifact (Linux) | |
| if: matrix.os == 'ubuntu-latest' | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: linux-executables | |
| path: dist/ | |
| - name: Create Artifact (macOS) | |
| if: matrix.os == 'macos-latest' | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: macos-executables | |
| path: dist/ | |
| - name: List files in dist folder | |
| run: ls -R ./dist/ | |
| - name: Upload Release Asset | |
| if: matrix.os == 'windows-latest' | |
| uses: actions/upload-release-asset@v1 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| with: | |
| upload_url: ${{ github.event.release.upload_url }} | |
| asset_path: dist/yasumi.exe | |
| asset_name: yasumi.exe | |
| asset_content_type: application/vnd.microsoft.portable-executable |