gl-auth now checks for and run a hook called 'gl-pre-git'
see sample code for motivation; other uses at your discretion
This commit is contained in:
parent
aab5ec9e6a
commit
396bfaa3b9
3 changed files with 41 additions and 0 deletions
10
hooks/common/gl-pre-git.hub-sample
Normal file
10
hooks/common/gl-pre-git.hub-sample
Normal file
|
@ -0,0 +1,10 @@
|
|||
#!/bin/bash
|
||||
|
||||
# sample pre-git hook to print pending hub requests
|
||||
|
||||
[ "$1" = "R" ] && exit 0 # we only want to print them on pushes
|
||||
|
||||
# print 'fetched' and 'pending' requests only
|
||||
SSH_ORIGINAL_COMMAND="hub list-requests $GL_REPO fetched pending" $GL_BINDIR/gl-auth-command $GL_USER
|
||||
|
||||
exit 0
|
Loading…
Add table
Add a link
Reference in a new issue