mirror of
https://github.com/dragonish/obsidian-heading-decorator.git
synced 2026-07-22 12:20:29 +00:00
49 lines
1.3 KiB
YAML
49 lines
1.3 KiB
YAML
name: Release
|
|
|
|
on:
|
|
push:
|
|
tags:
|
|
- '*'
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v6
|
|
with:
|
|
fetch-depth: 0
|
|
fetch-tags: true
|
|
- name: Setup pnpm
|
|
uses: pnpm/action-setup@v4
|
|
with:
|
|
version: 10
|
|
- name: Setup Node.js
|
|
uses: actions/setup-node@v4
|
|
with:
|
|
node-version: 22
|
|
cache: 'pnpm'
|
|
- name: Build package
|
|
run: |
|
|
pnpm install
|
|
pnpm run build
|
|
- name: Create changelog text
|
|
id: changelog_text
|
|
uses: dragonish/tag-changelog@v1
|
|
with:
|
|
token: ${{ secrets.GITHUB_TOKEN }}
|
|
config_file: .github/scripts/tag-changelog-config.cjs
|
|
- name: Get git tags
|
|
id: git_tags
|
|
run: |
|
|
current=$(git describe --abbrev=0 --tags)
|
|
echo "current=${current}" >> ${GITHUB_OUTPUT}
|
|
- name: Create release
|
|
uses: ncipollo/release-action@v1
|
|
with:
|
|
token: ${{ secrets.GITHUB_TOKEN }}
|
|
name: Release ${{ steps.git_tags.outputs.current }}
|
|
prerelease: false
|
|
draft: false
|
|
artifacts: "main.js,styles.css,manifest.json"
|
|
body: ${{ steps.changelog_text.outputs.changes }}
|