.github/workflows/Release.yaml
name: Release
on:
release:
types:
- created
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: 18
- name: Install dependencies
run: npm install
- name: Build with Webpack
run: npm run build:umd
- name: Create iztro-min-js
run: tar -czvf iztro-min-js.tar.gz dist/
- name: Upload iztro-min-js to Release
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: iztro-min-js.tar.gz
asset_name: iztro-min-js.tar.gz
asset_content_type: application/gzip
env:
GITHUB_TOKEN: ${{ secrets.GIT_AUTH_TOKEN }}