prpatch (216B)
1 #!/bin/sh 2 3 set -eo pipefail 4 5 if [ -z "$1" ]; then 6 printf "usage: prpatch <id> [owner/project]\n" 7 exit 1 8 fi 9 10 project=${2:-$(github-project-slug)} 11 id="$1" 12 13 curl -sL "https://github.com/${project}/pull/${id}.patch"