Skip to content

Add GH_TOKEN

Add GH_TOKEN #4

Workflow file for this run

name: Build and Release
on:
push:
tags:
- 'v*'
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '18'
- name: Install dependencies
run: npm install
- name: Build project
run: npm run build
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: build-artifact
path: dist/
release:
runs-on: ubuntu-latest
needs: build
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Download artifact
uses: actions/download-artifact@v4
with:
name: build-artifact
- name: Create GitHub Release
uses: softprops/action-gh-release@v4
with:
files: dist/*
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_TOKEN: ${{ secrets.PERSONAL_ACCESS_TOKEN }}