diff --git a/.github/workflows/update-sha.yml b/.github/workflows/update-sha.yml deleted file mode 100644 index e5418d9294..0000000000 --- a/.github/workflows/update-sha.yml +++ /dev/null @@ -1,50 +0,0 @@ -name: Update SHA - -on: issue_comment - -jobs: - update-pr-sha: - name: Update SHA - if: ${{ github.event.issue.pull_request && contains(github.event.comment.body, 'update-sha') }} - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - with: - token: ${{ secrets.BOT_TOKEN }} - - # would have been lit if github supported string split expression - - name: Extract branch name from comment to get commit SHA - uses: jungwinter/split@v2 - id: split - with: - msg: ${{ github.event.comment.body }} - - - name: Set up Python - uses: actions/setup-python@v4 - with: - python-version: '3.9' - - - name: Use CLA approved github bot - run: .github/scripts/use-cla-approved-github-bot.sh - - - name: Checkout Pull Request - env: - GITHUB_TOKEN: ${{ secrets.BOT_TOKEN }} - run: | - PR_URL="${{ github.event.issue.pull_request.url }}" - PR_NUM=${PR_URL##*/} - echo "Checking out from PR #$PR_NUM based on URL: $PR_URL" - hub pr checkout $PR_NUM - - # caching is not supported for this event type - - name: Run script - run: | - python -m pip install requests==2.28.1 ruamel.yaml==0.17.21 - python scripts/update_sha.py --branch ${{ steps.split.outputs._1 }} - - - name: Commit and Push changes - env: - GITHUB_TOKEN: ${{ secrets.BOT_TOKEN }} - run: | - git commit -a -m "Update SHA" - git push