2025.7.3 #177
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
| on: | |
| push: | |
| # Sequence of patterns matched against refs/tags | |
| tags: | |
| - '*' # Push events to matching v*, i.e. v1.0, v20.15.10 | |
| name: Upload Release Asset | |
| jobs: | |
| create_release: | |
| name: Create release | |
| runs-on: ubuntu-latest | |
| outputs: | |
| upload_url: ${{ steps.create_release.outputs.upload_url }} | |
| steps: | |
| - name: Create Release | |
| id: create_release | |
| uses: softprops/action-gh-release@v1 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| with: | |
| draft: false | |
| prerelease: false | |
| generate_release_notes: true | |
| build_release: | |
| name: Build Release | |
| needs: create_release | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| browser: ["edge", "chrome", "firefox"] | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v2 | |
| with: | |
| lfs: true | |
| - name: Branch name | |
| id: branch_name | |
| run: | | |
| echo ::set-output name=SOURCE_NAME::${GITHUB_REF#refs/*/} | |
| echo ::set-output name=SOURCE_BRANCH::${GITHUB_REF#refs/heads/} | |
| echo ::set-output name=SOURCE_TAG::${GITHUB_REF#refs/tags/v} | |
| - name: Set env | |
| run: | | |
| echo $SOURCE_NAME | |
| echo $SOURCE_BRANCH | |
| echo $SOURCE_TAG | |
| env: | |
| SOURCE_NAME: ${{ steps.branch_name.outputs.SOURCE_NAME }} | |
| SOURCE_BRANCH: ${{ steps.branch_name.outputs.SOURCE_BRANCH }} | |
| SOURCE_TAG: ${{ steps.branch_name.outputs.SOURCE_TAG }} | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '24' | |
| - name: Prepare files | |
| run: | | |
| npm ci | |
| PLATFORM=${{ matrix.browser }} npm run build | |
| mv build ${{ matrix.browser }} | |
| env: | |
| SOURCE_TAG: ${{ steps.branch_name.outputs.SOURCE_TAG }} | |
| - name: Zip Release | |
| uses: TheDoctor0/zip-release@master | |
| with: | |
| filename: 'FluentTyper_${{ matrix.browser }}.zip' | |
| directory: '${{ matrix.browser }}' | |
| - name: Upload Release Asset | |
| id: upload-release-asset | |
| uses: actions/upload-release-asset@v1 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| with: | |
| upload_url: ${{ needs.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps | |
| asset_path: ./${{ matrix.browser }}/FluentTyper_${{ matrix.browser }}.zip | |
| asset_name: FluentTyper_${{ matrix.browser }}.zip | |
| asset_content_type: application/zip |