Skip to content

build(deps): bump golang.org/x/tools from 0.1.5 to 0.19.0 #1085

build(deps): bump golang.org/x/tools from 0.1.5 to 0.19.0

build(deps): bump golang.org/x/tools from 0.1.5 to 0.19.0 #1085

name: Check Pull Request labels
on:
pull_request:
types: [opened, labeled, unlabeled, synchronize]
concurrency:
group: format('{0}-{1}', ${{ github.ref }}, 'Check Pull Request labels')
cancel-in-progress: true
jobs:
check_pull_request_labels:
name: Check Pull Request labels
timeout-minutes: 10
runs-on: ubuntu-latest
if: github.repository == 'vitessio/vitess'
steps:
- uses: mheap/github-action-required-labels@v1
name: Check release notes label
id: required_label
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
mode: exactly
count: 0
labels: "release notes (needs details)"
- name: Print helper
if: failure() && steps.required_label.outcome == 'failure'
run: |
echo The "release notes (needs details)" label is set. The changes made in this Pull Request need to be documented in the release notes summary "('./doc/releasenotes/12_0_0_summary.md')". Once documented, the "release notes (needs details)" label can be removed.
exit 1
- name: Check type and component labels
env:
PR_NUMBER: ${{ github.event.pull_request.number }}
run: |
LABELS_JSON="/tmp/labels.json"
# Get labels for this pull request
curl -s \
-H 'authorization: Bearer ${{ secrets.GITHUB_TOKEN }}' \
-H "Accept: application/vnd.github.v3+json" \
-H "Content-type: application/json" \
"https://api.github.com/repos/${GITHUB_REPOSITORY}/issues/${PR_NUMBER}/labels" \
> "$LABELS_JSON"
if ! cat ${LABELS_JSON} | jq -r '.[].name ' | grep -q 'Component:' ; then
echo "Expecting PR to have label 'Component: ...'"
exit 1
fi
if ! cat ${LABELS_JSON} | jq -r '.[].name ' | grep -q 'Type:' ; then
echo "Expecting PR to have label 'Type: ...'"
exit 1
fi