mirror of
https://github.com/lostpaul/obsidian-folder-notes.git
synced 2026-07-22 07:40:24 +00:00
41 lines
1 KiB
YAML
41 lines
1 KiB
YAML
# https://github.com/SilentVoid13/Templater/blob/master/.github/workflows/release.yml
|
|
|
|
name: Plugin-beta release
|
|
on:
|
|
push:
|
|
tags:
|
|
- "[0-9]+.[0-9]+.[0-9]+-[0-9]+-beta"
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout beta branch
|
|
uses: actions/checkout@v3
|
|
with:
|
|
ref: beta
|
|
|
|
- name: Fetch main branch
|
|
run: git fetch origin main
|
|
|
|
- name: Checkout main branch
|
|
run: git checkout main
|
|
|
|
- name: npm build
|
|
run: |
|
|
npm install
|
|
npm run build --if-present
|
|
|
|
- name: Set Release Name
|
|
id: set_release_name
|
|
run: echo "RELEASE_NAME=$(echo $GITHUB_REF | sed 's/refs\/tags\///')" >> $GITHUB_ENV
|
|
|
|
- name: Create Plugin beta release
|
|
uses: ncipollo/release-action@v1.12.0
|
|
with:
|
|
name: Beta release ${{ env.RELEASE_NAME }}
|
|
prerelease: true
|
|
artifacts: "main.js,manifest.json,styles.css"
|
|
token: ${{ secrets.GITHUB_TOKEN }}
|
|
tag: ${{ env.RELEASE_NAME }}
|