From f0eabd82c3fbd91bce2a49c9a2ad5fde5812d977 Mon Sep 17 00:00:00 2001 From: Luke Vella Date: Mon, 6 Feb 2023 19:07:09 +0000 Subject: [PATCH] =?UTF-8?q?=F0=9F=91=B7=20Add=20release=20workflow?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/release.yml | 24 ++++++++++++++++++++++++ 1 file changed, 24 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 000000000..30ba3f71a --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,24 @@ +on: + push: + tags: + - "v*" + +name: Create Release + +jobs: + build: + name: Create Release + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v3 + - name: Extract body from changelog + run: | + NEW_VERSION=$(echo '${{ github.ref }}' | sed 's/refs\/tags\/v//') + echo $NEW_VERSION + sed -n -e "/## ${NEW_VERSION}/,/ extractedBody.md + - name: Create Release + uses: ncipollo/release-action@v1 + with: + token: ${{ secrets.GITHUB_TOKEN }} + bodyFile: "extractedBody.md"