Fix WF name #34
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: Store Dist Artifact | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- master | |
workflow_dispatch: | |
jobs: | |
upload-dist: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version-file: ".nvmrc" | |
cache: "npm" | |
- name: Install dependencies | |
run: npm ci | |
- name: Install ncc | |
run: npm i -g @vercel/ncc | |
- name: Rebuild the dist/ directory | |
run: npm run build | |
- name: Store Dist | |
uses: actions/upload-artifact@v3 | |
with: | |
name: "dist" | |
path: "dist/" | |
retention-days: 3 | |
check-dist: | |
needs: ["upload-dist"] | |
if: always() | |
runs-on: ubuntu-22.04 | |
outputs: | |
has-dist: ${{ steps.check_dist.outputs.exists }} | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: "./" | |
name: "Check dist exists" | |
id: check_dist | |
with: | |
name: "dist" |