apply-pr.sh 233 B

1234567891011
  1. #!/usr/bin/env bash
  2. if [ $# -eq 0 ]; then
  3. echo "usage: $0 <pull-request-number>"
  4. exit 1
  5. fi
  6. BASE="https://github.com/commaai/openpilot/pull/"
  7. PR_NUM="$(echo $1 | grep -o -E '[0-9]+')"
  8. curl -L $BASE/$PR_NUM.patch | git apply -3