Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
node-version: '22'
cache: 'npm'

- name: Install dependencies
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
node-version: '22'
cache: 'npm'

- name: Install dependencies
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/security-scan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
node-version: '22'
cache: 'npm'

- name: Install dependencies
Expand Down
69 changes: 69 additions & 0 deletions .github/workflows/semantic-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
# Bumps package.json / CHANGELOG.md and creates Git tags via semantic-release from conventional commits.
# Optional secret SEMANTIC_RELEASE_GITHUB_TOKEN (PAT with contents:write) improves push reliability;
# if unset, GITHUB_TOKEN is used as GH_TOKEN / GITHUB_TOKEN per semantic-release documentation.

name: Semantic Release

on:
workflow_dispatch:

concurrency:
group: semantic-release-${{ github.repository }}-${{ github.ref }}
cancel-in-progress: false

jobs:
semantic-release:
environment: production
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
persist-credentials: true
token: ${{ secrets.SEMANTIC_RELEASE_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}

- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: '1.25'

- name: Run Go tests
working-directory: crossview-go-server
run: go test ./...

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
cache: 'npm'

- name: Install dependencies
run: |
npm ci
npm install --no-save @rollup/rollup-linux-x64-gnu || true

- name: Run npm audit
run: |
echo "Checking for npm vulnerabilities..."
npm audit --audit-level=moderate || echo "⚠️ Some vulnerabilities found, but continuing build"

- name: Run semantic-release
env:
GH_TOKEN: ${{ secrets.SEMANTIC_RELEASE_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.SEMANTIC_RELEASE_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
run: npx semantic-release --ci

- name: Report result
if: always()
run: |
if [ -f .semantic-release-version ]; then
VERSION=$(tr -d '\n\r' < .semantic-release-version)
echo "Published version ${VERSION} (tag v${VERSION})."
echo "### Published v${VERSION}" >> "$GITHUB_STEP_SUMMARY"
else
echo "No new semantic version published (nothing releasable)."
echo "### No release published" >> "$GITHUB_STEP_SUMMARY"
fi
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# semantic-release CI marker (never commit)
.semantic-release-version

# Logs
logs
*.log
Expand Down
Loading