diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..41d8729 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,32 @@ +name: Release + +on: + workflow_dispatch: + +permissions: + contents: write + +jobs: + release-please: + runs-on: ubuntu-latest + # outputs: + # release_created: ${{ steps.release.outputs.release_created }} + # tag_name: ${{ steps.release.outputs.tag_name }} + steps: + - name: Get Version + id: json_properties + uses: ActionsTools/read-json-action@main + with: + file_path: "package.json" + - uses: actions/checkout@v4 + - name: Tag Major & Minor + run: | + git config user.name "Zeon-neon [ACTIONS]" + git config user.email zeon@saahild.com + git tag -d v${{ steps.json_properties.outputs.version }} || true + + git push origin :v${{ steps.json_properties.outputs.version}} || true + + git tag -a v${{ steps.json_properties.outputs.version }} -m "v${{ steps.json_properties.outputs.version }}" + + git push origin v${{ steps.json_properties.outputs.version}}