From d890875a73d100dd6e67cee1b8c44b0066449dbd Mon Sep 17 00:00:00 2001 From: Steven Hubert Date: Fri, 22 Nov 2024 09:19:23 -0700 Subject: [PATCH] Add release workflow --- .github/workflows/release.yml | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..29e673d --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,30 @@ +name: Release Obsidian theme + +on: + push: + tags: + - "*" # Trigger the workflow when a tag is pushed + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + + - name: Install GitHub CLI + run: sudo apt-get install gh + + - name: Create release + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + # Extract the tag name from GITHUB_REF + tag="${GITHUB_REF#refs/tags/}" + + # Create a release with the tag name and attach assets + gh release create "$tag" \ + --title="$tag" \ + --generate-notes \ + --draft \ + manifest.json theme.css