Release and tar file with CI

This commit is contained in:
timendum 2025-07-16 18:09:56 +02:00
commit d45eb79bb5

View file

@ -84,6 +84,34 @@ jobs:
labels: ${{ steps.meta.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max
build-and-upload-release:
name: Build and Upload build to Github Release
runs-on: ubuntu-latest
needs:
- test-and-build
- e2e-test
if: github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/v')
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: '18'
- name: Install dependencies
run: npm install
- name: Build project
run: npm run build
- name: Create archives
run: |
tar -cvzf release.tar.gz -C dist $(ls dist)
- name: Upload Binaries to Release
if: startsWith(github.ref, 'refs/tags/v')
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
tag: ${{ github.ref_name }}
file: release.tar.gz
deploy:
if: github.ref == 'refs/heads/main'
needs: