|
- #!/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
|