mirror of
https://github.com/jarrodwatts/claude-hud.git
synced 2026-04-16 06:32:39 +00:00
43 lines
919 B
YAML
43 lines
919 B
YAML
name: Build dist
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
|
|
concurrency:
|
|
group: build-dist
|
|
cancel-in-progress: false
|
|
|
|
permissions:
|
|
contents: write
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
if: "!contains(github.event.head_commit.message, '[auto]')"
|
|
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
with:
|
|
token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- uses: actions/setup-node@v6
|
|
with:
|
|
node-version: '20'
|
|
cache: 'npm'
|
|
|
|
- run: npm ci
|
|
- run: npm test
|
|
- run: npm run build
|
|
|
|
- name: Verify build output
|
|
run: test -f dist/index.js || exit 1
|
|
|
|
- name: Commit dist/
|
|
run: |
|
|
git config user.name "github-actions[bot]"
|
|
git config user.email "github-actions[bot]@users.noreply.github.com"
|
|
git add dist/ --force
|
|
git diff --staged --quiet || git commit -m "build: compile dist/ [auto]"
|
|
git push
|