From 35d55b57b1d8e61ce8756f418c4e9ba84879fac3 Mon Sep 17 00:00:00 2001 From: Andreas Baumgartner Date: Sun, 9 Jun 2024 15:38:36 +0200 Subject: [PATCH] Add action for uploading dist/ on release --- .github/workflows/upload-dist.yml | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 .github/workflows/upload-dist.yml diff --git a/.github/workflows/upload-dist.yml b/.github/workflows/upload-dist.yml new file mode 100644 index 0000000..776f99c --- /dev/null +++ b/.github/workflows/upload-dist.yml @@ -0,0 +1,20 @@ +name: Upload dist/ + +on: + release: + types: [created] + +jobs: + upload-dist: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: '20' + - run: npm install + - run: npm run build + - run: zip -r $GITHUB_REF_NAME-dist.zip dist/ + - run: gh release upload $GITHUB_REF_NAME $GITHUB_REF_NAME-dist.zip + env: + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file