gl-reflog adc gains 'usage', loses some crappy warnings
(actually these warnings can come in many other situations; I just noticed them when testing this adc)
This commit is contained in:
parent
5b3dcb3757
commit
6386d8ca2f
|
@ -13,13 +13,20 @@ use warnings;
|
|||
# - heavily dependent on the gitolite log file format (duh!)
|
||||
# - cannot recover if some other commits were made after the force push
|
||||
|
||||
# USAGE
|
||||
# ssh git@server gl-reflog show r1 refs/heads/b1
|
||||
# # shows last 10 updates to branch b1 in repo r1
|
||||
# ssh git@server gl-reflog show r1 refs/heads/b1 20
|
||||
# # shows last 20 entries...
|
||||
# ssh git@server gl-reflog recover r1 refs/heads/b1
|
||||
# # recovers the last update to b1 in r1 if it was a "+"
|
||||
sub usage {
|
||||
print STDERR <<'EOF';
|
||||
USAGE
|
||||
ssh git@server gl-reflog show r1 refs/heads/b1
|
||||
# shows last 10 updates to branch b1 in repo r1
|
||||
ssh git@server gl-reflog show r1 refs/heads/b1 20
|
||||
# shows last 20 entries...
|
||||
ssh git@server gl-reflog recover r1 refs/heads/b1
|
||||
# recovers the last update to b1 in r1 if it was a "+"
|
||||
EOF
|
||||
exit 1;
|
||||
}
|
||||
|
||||
usage unless (@ARGV >= 3);
|
||||
|
||||
# NOTES
|
||||
# - the verb "recover" is used because this is expected to be used most often
|
||||
|
|
|
@ -320,6 +320,7 @@ sub new_repo
|
|||
# pull in basic group info
|
||||
unless ($cache_filled) {
|
||||
local(%repos, %groups);
|
||||
local $^W = 0;
|
||||
# read group info from compiled config. At the time we're called
|
||||
# this info has not yet been pulled in by the rest of the code, so
|
||||
# we need to do this specially here. However, the info we're
|
||||
|
|
Loading…
Reference in a new issue