andre482_O-tie/.github/workflows/release.yml
Andre482 a3f01bb92b Document Obsidian-compatible release tags (1.0.1, not v1.0.1).
Restrict the release workflow to semver tags without a v prefix so manifest.json and GitHub releases stay aligned.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-18 22:23:30 +03:00

44 lines
1.1 KiB
YAML

name: Release
# Obsidian Community Plugins require the GitHub tag to match manifest.json
# exactly (e.g. 1.0.1 — not v1.0.1).
# Create releases with: git tag 1.0.1 && git push origin 1.0.1
on:
push:
tags:
- "[0-9]+.[0-9]+.[0-9]+"
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
id-token: write
attestations: write
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
- run: npm ci
- run: npm run build
- name: Attest plugin artifacts
uses: actions/attest-build-provenance@v2
with:
subject-path: |
main.js
manifest.json
styles.css
- name: Delete existing release
env:
GH_TOKEN: ${{ github.token }}
run: gh release delete "${{ github.ref_name }}" --yes || true
- name: Create release
uses: softprops/action-gh-release@v2
with:
generate_release_notes: true
files: |
main.js
manifest.json
styles.css