Skip to content

Release

Release #2

Workflow file for this run

name: Release
on:
push:
tags: ['*']
workflow_dispatch:
jobs:
build:
runs-on: self-hosted
permissions:
contents: write
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "16"
- name: Create package
run: |
rm -rf *.tar.gz
npx --yes wspackager@latest
- name: Check file existence
id: check_files
uses: andstor/file-existence-action@v3
with:
files: "*.tar.gz"
- name: On Build Failure
if: steps.check_files.outputs.files_exists == 'false'
run: |
echo "Packaging FAILED" && exit 1
- name: Release
uses: softprops/action-gh-release@v2
if: startsWith(github.ref, 'refs/tags/') && steps.check_files.outputs.files_exists == 'true'
with:
files: "*.tar.gz"