Skip to content

Fixing incorrect uses of halt_error #231

Fixing incorrect uses of halt_error

Fixing incorrect uses of halt_error #231

Workflow file for this run

# Run tests for jq or test files modified in this PR.
name: jq / pr
on: pull_request
jobs:
ci:
runs-on: ubuntu-latest
steps:
- name: Checkout PR
uses: actions/checkout@v3
- name: Install software
run: sudo apt update && sudo apt -y install jq bats
- name: Run tests for changed/added exercises
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
pr_endpoint=$(jq -r '"repos/\(.repository.full_name)/pulls/\(.pull_request.number)"' "$GITHUB_EVENT_PATH")
gh api "$pr_endpoint/files" --paginate --jq '
.[] |
select(.status | IN("added", "modified", "renamed")) |
select(.filename | test("\\.(jq|bats|bash)$")) |
.filename
' | xargs -r bash bin/pr