Bump version to 1.0.1 #6
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build and Release | |
on: | |
push: | |
tags: | |
- 'v*' | |
jobs: | |
build-and-release: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: '20' | |
- name: Install dependencies | |
run: npm ci | |
- name: Build project | |
run: npm run build | |
- name: Verify release versions | |
run: npm run release_verify | |
- name: Get version from dist/manifest.json | |
id: get_version | |
run: | | |
VERSION=$(jq -r .version ./dist/manifest.json) | |
echo "version=$VERSION" >> $GITHUB_OUTPUT | |
- name: Create ZIP file | |
run: | | |
cd dist | |
zip -r ../quickcite-${{ steps.get_version.outputs.version }}.zip * | |
- name: Create Release | |
id: create_release | |
uses: actions/create-release@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag_name: ${{ github.ref }} | |
release_name: Release ${{ steps.get_version.outputs.version }} | |
draft: false | |
prerelease: false | |
- name: Upload Release Asset | |
uses: actions/upload-release-asset@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
upload_url: ${{ steps.create_release.outputs.upload_url }} | |
asset_path: ./quickcite-${{ steps.get_version.outputs.version }}.zip | |
asset_name: quickcite-${{ steps.get_version.outputs.version }}.zip | |
asset_content_type: application/zip |