Skip to content

ci: fix release workflow #2

ci: fix release workflow

ci: fix release workflow #2

Workflow file for this run

name: Build
on: [push]
env:
is_tag: ${{ startsWith(github.ref, 'refs/tags/') }}
jobs:
publish:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: ['lts']
steps:
- uses: actions/checkout@v3
- name: Set up Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'pnpm'
- name: Bundle project
run: |
pnpm install
pnpm run build
- name: Install zip
run: sudo apt-get install -y zip
- name: Create archive
working-directory: ${{env.GITHUB_WORKSPACE}}
run: zip -r mpv-cut.zip dist
- name: Upload
uses: actions/upload-artifact@v4
with:
name: mpv-cut
path: |
mpv-cut.zip
- name: Release
uses: softprops/action-gh-release@v1
if: ${{ env.is_tag == 'true' }}
with:
files: |
mpv-cut.zip
fail_on_unmatched_files: true