1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253 |
- #!/bin/sh
- remote="$1"
- url="$2"
- z40=0000000000000000000000000000000000000000
- while read local_ref local_sha remote_ref remote_sha
- do
- if [ "$local_sha" = $z40 ]
- then
-
- :
- else
- if [ "$remote_sha" = $z40 ]
- then
-
- range="$local_sha"
- else
-
- range="$remote_sha..$local_sha"
- fi
-
- commit=`git rev-list -n 1 --grep '^WIP' "$range"`
- if [ -n "$commit" ]
- then
- echo >&2 "Found WIP commit in $local_ref, not pushing"
- exit 1
- fi
- fi
- done
- exit 0
|