summaryrefslogtreecommitdiff
path: root/etc/functions/git-hook
diff options
context:
space:
mode:
Diffstat (limited to 'etc/functions/git-hook')
-rw-r--r--etc/functions/git-hook6
1 files changed, 1 insertions, 5 deletions
diff --git a/etc/functions/git-hook b/etc/functions/git-hook
index f20c988..bb44e05 100644
--- a/etc/functions/git-hook
+++ b/etc/functions/git-hook
@@ -3,7 +3,7 @@
## Written 2008 by Daniel Friesel <derf@derf.homelinux.org>
autoload fdie
-typeset hook_dir action=$1 hook=$2
+typeset hook_dir action=${1=list} hook=$2
if [[ -n $GIT_DIR && -d $GIT_DIR ]] {
hook_dir=$GIT_DIR/hooks
@@ -23,10 +23,6 @@ function usage {
ENDOFHELP
}
-if [[ $#* < 1 ]] {
- usage; return
-}
-
function hook_enable {
if [[ -e $hook_dir/$hook ]] {
if ! [[ -x $hook_dir/$hook ]] {