diff options
Diffstat (limited to 'etc/git')
| -rwxr-xr-x | etc/git/pre-push | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/etc/git/pre-push b/etc/git/pre-push index 2b3e6fe228a..c3887ec0227 100755 --- a/etc/git/pre-push +++ b/etc/git/pre-push | |||
| @@ -1,8 +1,9 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | 2 | ||
| 3 | # This hook script prevents the user from pushing to Savannah if any of the new | 3 | # This hook script prevents the user from pushing to the project's Git repo if |
| 4 | # commits' OpenPGP signatures cannot be verified, or if a commit is signed | 4 | # any of the new commits' OpenPGP signatures cannot be verified, if a commit is |
| 5 | # with an unauthorized key. | 5 | # signed with an unauthorized key, or if the channel news file is malformed |
| 6 | # (which would break the build). | ||
| 6 | 7 | ||
| 7 | # Called by "git push" after it has checked the remote status, but before | 8 | # Called by "git push" after it has checked the remote status, but before |
| 8 | # anything has been pushed. If this script exits with a non-zero status nothing | 9 | # anything has been pushed. If this script exits with a non-zero status nothing |
| @@ -33,8 +34,8 @@ perform_checks() { | |||
| 33 | main() { | 34 | main() { |
| 34 | while read local_ref local_hash remote_ref remote_hash | 35 | while read local_ref local_hash remote_ref remote_hash |
| 35 | do | 36 | do |
| 36 | # When deleting a remote branch, no commits are pushed to the remote, and | 37 | # When deleting a remote branch, no commits are pushed to the remote, |
| 37 | # thus there are no signatures to be verified. | 38 | # and thus there are no signatures or news updates to be verified. |
| 38 | if [ "$local_hash" != $z40 ] | 39 | if [ "$local_hash" != $z40 ] |
| 39 | then | 40 | then |
| 40 | # Skip the hook when performing a pull-request. | 41 | # Skip the hook when performing a pull-request. |
