summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgitolite tester <tester@example.com>2012-11-12 11:25:23 +0530
committerSitaram Chamarty <sitaram@atc.tcs.com>2012-11-13 08:09:14 +0530
commit57760d7e1bbff68629e2489f84fdeb0ffe83ef7d (patch)
tree8e44bcd01dfc11b78a086127e6d454166b242cc4
parentgl-conf must be created even if the repo para has only config lines (diff)
downloadgitolite-gentoo-57760d7e1bbff68629e2489f84fdeb0ffe83ef7d.tar.gz
gitolite-gentoo-57760d7e1bbff68629e2489f84fdeb0ffe83ef7d.tar.bz2
gitolite-gentoo-57760d7e1bbff68629e2489f84fdeb0ffe83ef7d.zip
refex-expr: die when admin forgets to add the required line to the rc
-rwxr-xr-xsrc/VREF/refex-expr2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/VREF/refex-expr b/src/VREF/refex-expr
index 3ff4bf4..d0a51b7 100755
--- a/src/VREF/refex-expr
+++ b/src/VREF/refex-expr
@@ -3,6 +3,8 @@ use strict;
use warnings;
my $rule = $ARGV[7];
+die "\n\nFATAL: GL_REFEX_EXPR_ doesn't exist\n(your admin probably forgot the rc file change needed for this to work)\n\n"
+ unless exists $ENV{"GL_REFEX_EXPR_" . $rule};
my $res = $ENV{"GL_REFEX_EXPR_" . $rule} || 0;
print "$ARGV[6] ($res)\n" if $res;