630152270f
Changed both CI and publish workflows to target local self-hosted runner instead of GitHub-hosted ubuntu-latest. Changes: - .github/workflows/ci.yml: runs-on: local-ubuntu-latest - .github/workflows/publish.yml: runs-on: local-ubuntu-latest Generated with [Claude Code](https://claude.ai/code) via [Happy](https://happy.engineering) Co-Authored-By: Claude <noreply@anthropic.com> Co-Authored-By: Happy <yesreply@happy.engineering>
55 lines
1.3 KiB
YAML
55 lines
1.3 KiB
YAML
name: Publish Plugin
|
|
|
|
on:
|
|
push:
|
|
tags:
|
|
- 'v*'
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
build-and-publish:
|
|
runs-on: local-ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Setup Node.js
|
|
uses: actions/setup-node@v4
|
|
with:
|
|
node-version: '20'
|
|
registry-url: 'https://registry.npmjs.org'
|
|
|
|
- name: Install dependencies
|
|
working-directory: ./headlamp-sealed-secrets
|
|
run: npm ci
|
|
|
|
- name: Run type check
|
|
working-directory: ./headlamp-sealed-secrets
|
|
run: npm run tsc
|
|
|
|
- name: Run linter
|
|
working-directory: ./headlamp-sealed-secrets
|
|
run: npm run lint
|
|
|
|
- name: Build plugin
|
|
working-directory: ./headlamp-sealed-secrets
|
|
run: npm run build
|
|
|
|
- name: Publish to NPM
|
|
working-directory: ./headlamp-sealed-secrets
|
|
run: npm publish
|
|
env:
|
|
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
|
|
|
- name: Create GitHub Release
|
|
uses: softprops/action-gh-release@v1
|
|
with:
|
|
files: |
|
|
headlamp-sealed-secrets/dist/main.js
|
|
headlamp-sealed-secrets/package.json
|
|
headlamp-sealed-secrets/README.md
|
|
generate_release_notes: true
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|