From dfc941618d297148941632b5f0b54cd1ba8eb71c Mon Sep 17 00:00:00 2001 From: ArmanTaheriGhaleTaki Date: Sat, 11 Jan 2025 02:01:24 -0600 Subject: [PATCH] chore(): Add auto-realease action --- .github/workflows/auto-realease.yml | 36 +++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 .github/workflows/auto-realease.yml diff --git a/.github/workflows/auto-realease.yml b/.github/workflows/auto-realease.yml new file mode 100644 index 0000000..801899d --- /dev/null +++ b/.github/workflows/auto-realease.yml @@ -0,0 +1,36 @@ +name: Deploy + +on: + release: + types: [published] + +jobs: + init: + name: 🚩 Initialize + runs-on: ubuntu-latest + steps: + - name: Cancel previous workflow + uses: styfle/cancel-workflow-action@0.12.1 + with: + access_token: ${{ github.token }} + + release: + name: 🚀 Release + needs: init + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + + - name: Setup NodeJS + uses: actions/setup-node@v3 + with: + node-version: lts/* + + - name: Release + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + cp .github/.releaserc.yml . + npm i -g semantic-release @semantic-release/changelog @semantic-release/git + semantic-release \ No newline at end of file