Skip to content

Commit

Permalink
Add release workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
nya3jp committed May 23, 2024
1 parent 9f41353 commit dd79427
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: release

on:
push:
tags:
- "v*.*.*"

jobs:
release:
name: Publish a release
runs-on: ubuntu-latest
steps:
- name: Set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/v}" >> $GITHUB_ENV
- name: Checkout
uses: actions/checkout@v4
- name: Create an archive
run: git archive --format tar.gz --prefix rules_contest-${RELEASE_VERSION}/ -o rules_contest-${RELEASE_VERSION}.tar.gz ${GITHUB_REF}
- name: Release
uses: softprops/action-gh-release@v2
with:
files: "rules_contest-${{ env.RELEASE_VERSION }}.tar.gz"
env:
RELEASE_VERSION: unknown

0 comments on commit dd79427

Please sign in to comment.