diff --git a/.forgejo/workflows/create-release.yaml b/.forgejo/workflows/create-release.yaml new file mode 100755 index 0000000..99df423 --- /dev/null +++ b/.forgejo/workflows/create-release.yaml @@ -0,0 +1,33 @@ +name: Create release on tag push + +on: + push: + tags: + - '*' + +jobs: + build: + name: Create release + runs-on: ubuntu-latest + permissions: + contents: write + + steps: + - name: Checkout source code + uses: actions/checkout@v4 + + - name: Get release body + run: | + echo "release_body=$(cat CHANGELOG.md)" >> "$GITHUB_ENV" + + - name: Setup Go + uses: actions/setup-go@v4 + with: + go-version: '>=1.20.1' + + - name: Draft release + uses: https://gitea.com/actions/release-action@main + with: + body: ${{ env.release_body }} + draft: true + api_key: '${{ secrets.RELEASE_TOKEN }}' diff --git a/.github/workflows/auto-pull-request.yaml b/.github/workflows/auto-pull-request.yaml deleted file mode 100644 index e314be9..0000000 --- a/.github/workflows/auto-pull-request.yaml +++ /dev/null @@ -1,20 +0,0 @@ -name: Pull Request on Branch Push - -on: - push: - branches-ignore: - - develop - - release - -jobs: - auto-pull-request: - name: Open pull request - runs-on: ubuntu-latest - steps: - - name: pull-request-action - uses: vsoch/pull-request-action@1.0.19 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - PULL_REQUEST_BRANCH: "develop" - PULL_REQUEST_DRAFT: true - PASS_IF_EXISTS: true diff --git a/.github/workflows/create-release.yaml b/.github/workflows/create-release.yaml index ffe88f7..47d456f 100644 --- a/.github/workflows/create-release.yaml +++ b/.github/workflows/create-release.yaml @@ -1,9 +1,9 @@ -name: Create release on tag push +name: Create release on tag push on: push: tags: - - 'release/*' + - '*' jobs: build: