Close Operator PR #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Close Operator PR | |
on: | |
workflow_dispatch: | |
inputs: | |
url: | |
description: "Operator PR URL to close" | |
required: true | |
permissions: | |
contents: read | |
jobs: | |
pr-update: | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Close PR | |
run: | | |
gh pr view ${{ inputs.url }} | |
rc=$? | |
if [ ${rc} -eq 0 ]; then | |
echo "Closing PR ${{ inputs.url }}" | |
gh pr close ${{ inputs.url }} | |
echo $? | |
else | |
echo "${{ inputs.url }} does not exist" | |
fi | |
env: | |
GITHUB_TOKEN: ${{ secrets.NGINX_PAT }} |