From ce7600eea71efccb27a824a2fd1a8ecf57ad2fc1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fatih=20T=C3=BCrken?= Date: Tue, 7 Mar 2023 18:38:20 +0300 Subject: [PATCH] Remove old workflow and reuse new one: - backport.yml - commands.yml - tag.yml --- .github/workflows/backport.yml | 23 ++--------------------- .github/workflows/commands.yml | 28 ++-------------------------- .github/workflows/tag.yaml | 20 ++++++-------------- 3 files changed, 10 insertions(+), 61 deletions(-) diff --git a/.github/workflows/backport.yml b/.github/workflows/backport.yml index abda3b1a86..c77b21ef0c 100644 --- a/.github/workflows/backport.yml +++ b/.github/workflows/backport.yml @@ -11,24 +11,5 @@ on: # See also commands.yml for the /backport triggered variant of this workflow. jobs: - # NOTE(negz): I tested many backport GitHub actions before landing on this - # one. Many do not support merge commits, or do not support pull requests with - # more than one commit. This one does. It also handily links backport PRs with - # new PRs, and provides commentary and instructions when it can't backport. - # The main gotchas with this action are that it _only_ supports merge commits, - # and that PRs _must_ be labelled before they're merged to trigger a backport. - open-pr: - runs-on: ubuntu-22.04 - if: github.event.pull_request.merged - steps: - - name: Checkout - uses: actions/checkout@v3 - with: - fetch-depth: 0 - - - name: Open Backport PR - uses: zeebe-io/backport-action@v0.0.8 - with: - github_token: ${{ secrets.GITHUB_TOKEN }} - github_workspace: ${{ github.workspace }} - version: v0.0.8 + backport: + uses: upbound/uptest/.github/workflows/provider-backport.yml@main diff --git a/.github/workflows/commands.yml b/.github/workflows/commands.yml index d300a4a0a2..cbbd0db78f 100644 --- a/.github/workflows/commands.yml +++ b/.github/workflows/commands.yml @@ -3,29 +3,5 @@ name: Comment Commands on: issue_comment jobs: - backport: - runs-on: ubuntu-22.04 - if: github.event.issue.pull_request && startsWith(github.event.comment.body, '/backport') - steps: - - name: Extract Command - id: command - uses: xt0rted/slash-command-action@v1 - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} - command: backport - reaction: "true" - reaction-type: "eyes" - allow-edits: "false" - permission-level: write - - - name: Checkout - uses: actions/checkout@v2 - with: - fetch-depth: 0 - - - name: Open Backport PR - uses: zeebe-io/backport-action@v0.0.4 - with: - github_token: ${{ secrets.GITHUB_TOKEN }} - github_workspace: ${{ github.workspace }} - version: v0.0.4 + comment-commands: + uses: upbound/uptest/.github/workflows/provider-commands.yml@main diff --git a/.github/workflows/tag.yaml b/.github/workflows/tag.yaml index 96a8af769f..2a93895ad8 100644 --- a/.github/workflows/tag.yaml +++ b/.github/workflows/tag.yaml @@ -1,7 +1,7 @@ name: Tag on: - workflow_dispatch: + workflow_dispatch: inputs: version: description: 'Release version (e.g. v0.1.0)' @@ -11,16 +11,8 @@ on: required: true jobs: - create-tag: - runs-on: ubuntu-22.04 - - steps: - - name: Checkout - uses: actions/checkout@v2 - - - name: Create Tag - uses: negz/create-tag@v1 - with: - version: ${{ github.event.inputs.version }} - message: ${{ github.event.inputs.message }} - token: ${{ secrets.GITHUB_TOKEN }} + tag: + uses: upbound/uptest/.github/workflows/provider-tag.yml@main + with: + version: ${{ github.event.inputs.version }} + message: ${{ github.event.inputs.message }}