Skip to content

release

release #63

Workflow file for this run

name: release
on:
push:
tags:
- "v*"
jobs:
release:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [18.x]
steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- name: Build
run: |
npm install
npm run build
- name: Create dist.zip
run: zip -r dist.zip dist
- name: Create dist.tar.gz
run: tar -zcvf dist.tar.gz dist
- name: Get version
id: get_version
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\/v/}
- uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
automatic_release_tag: "v${{ steps.get_version.outputs.VERSION }}"
title: "Version ${{ steps.get_version.outputs.VERSION }}"
prerelease: ${{ contains(steps.get_version.outputs.VERSION, 'rc') || contains(steps.get_version.outputs.VERSION, 'beta') || contains(steps.get_version.outputs.VERSION, 'alpha') }}
files: |
dist.zip
dist.tar.gz