aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRob Cowsill <42620235+rcowsill@users.noreply.github.com>2021-10-15 15:08:12 +0100
committerGitHub <noreply@github.com>2021-10-15 15:08:12 +0100
commit4c4a41c70c8a86efd6b9168bafc9ad2d2f21e7e0 (patch)
treeb33025269e17056a46b9d2e63237bf4c6fc5878d
parent5fd4557573c73a6b41b702b1ee39151b5bd7e5fd (diff)
downloadrneovim-4c4a41c70c8a86efd6b9168bafc9ad2d2f21e7e0.tar.gz
rneovim-4c4a41c70c8a86efd6b9168bafc9ad2d2f21e7e0.tar.bz2
rneovim-4c4a41c70c8a86efd6b9168bafc9ad2d2f21e7e0.zip
ci(labeler): Remove checkout steps
Sets GH_REPO and passes PR number to `gh`, making checkout unnecessary
-rw-r--r--.github/workflows/labeler.yml10
1 files changed, 5 insertions, 5 deletions
diff --git a/.github/workflows/labeler.yml b/.github/workflows/labeler.yml
index 4aa56f5d0e..76fc8793fa 100644
--- a/.github/workflows/labeler.yml
+++ b/.github/workflows/labeler.yml
@@ -19,12 +19,12 @@ jobs:
pull-requests: write
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+ GH_REPO: ${{ github.repository }}
+ PR_NUMBER: ${{ github.event.pull_request.number }}
+ PR_TITLE: ${{ github.event.pull_request.title }}
steps:
- - uses: actions/checkout@v2.3.1
- - run: gh pr checkout ${{ github.event.pull_request.number }}
-
# Extract type and try to add it as a label
- - run: gh pr edit --add-label "$(echo "${{ github.event.pull_request.title }}" | sed -E 's|([[:alpha:]]+)(\(.*\))?!?:.*|\1|')" || true
+ - run: gh pr edit "$PR_NUMBER" --add-label "$(echo "$PR_TITLE" | sed -E 's|([[:alpha:]]+)(\(.*\))?!?:.*|\1|')" || true
# Extract scope and try to add it as a label
- - run: gh pr edit --add-label "$(echo "${{ github.event.pull_request.title }}" | sed -E 's|[[:alpha:]]+\((.+)\)!?:.*|\1|')" || true
+ - run: gh pr edit "$PR_NUMBER" --add-label "$(echo "$PR_TITLE" | sed -E 's|[[:alpha:]]+\((.+)\)!?:.*|\1|')" || true