Bump the all-cargo group across 1 directory with 16 updates #784
This file contains hidden or 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: Vet | |
| permissions: | |
| contents: read | |
| pull-requests: write | |
| on: | |
| pull_request: | |
| types: [opened, edited, synchronize, reopened] | |
| jobs: | |
| vet: | |
| if: github.event.pull_request.draft == false | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v7 | |
| with: | |
| fetch-depth: 0 | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.11" | |
| - run: pip install verify-everything==0.1.6 | |
| - name: Run vet | |
| if: github.event.pull_request.head.repo.full_name == github.repository | |
| env: | |
| ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }} | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| VET_GOAL: | | |
| ${{ github.event.pull_request.title }} | |
| Additional context (not necessarily part of the goal): | |
| ${{ github.event.pull_request.body }} | |
| run: | | |
| set +e | |
| vet "$VET_GOAL" --quiet --output-format github \ | |
| --base-commit "${{ github.event.pull_request.base.sha }}" \ | |
| > "$RUNNER_TEMP/review.json" | |
| status=$? | |
| if [ "$status" -ne 0 ] && [ "$status" -ne 10 ]; then exit "$status"; fi | |
| jq --arg sha "${{ github.event.pull_request.head.sha }}" \ | |
| '. + {commit_id: $sha}' "$RUNNER_TEMP/review.json" > "$RUNNER_TEMP/review-final.json" | |
| gh api "repos/${{ github.repository }}/pulls/${{ github.event.pull_request.number }}/reviews" \ | |
| --method POST --input "$RUNNER_TEMP/review-final.json" > /dev/null || \ | |
| gh pr comment "${{ github.event.pull_request.number }}" \ | |
| --body "$(jq -r '[.body] + [.comments[] | "**\(.path):\(.line)**\n\n\(.body)"] | join("\n\n---\n\n")' "$RUNNER_TEMP/review-final.json")" | |
| exit 0 |