Archived
1
0

Install gl-pre-git at the right place

This commit is contained in:
Mercier Pierre-Olivier 2013-10-07 16:42:02 +02:00
parent b126a0400a
commit ad9c91497c
2 changed files with 6 additions and 1 deletions

View File

@ -16,7 +16,9 @@ install:
$(MAKEDIR) -p $(DEST) $(MAKEDIR) -p $(DEST)
$(COPY) -r ACU/ $(DEST) $(COPY) -r ACU/ $(DEST)
! test -d $(GITOLITE_DEST) || $(MAKEDIR) -p $(GITOLITE_DEST)/update.secondary.d ! test -d $(GITOLITE_DEST) || $(MAKEDIR) -p $(GITOLITE_DEST)/update.secondary.d
! test -d $(GITOLITE_DEST) || $(COPY) hooks/* $(GITOLITE_DEST)/update.secondary.d/ ! test -d $(GITOLITE_DEST) || $(COPY) hooks/gl-pre-git $(GITOLITE_DEST)/
! test -d $(GITOLITE_DEST) || $(COPY) hooks/subjects.pl $(GITOLITE_DEST)/update.secondary.d/
! test -d $(GITOLITE_DEST) || $(COPY) hooks/submissions.pl $(GITOLITE_DEST)/update.secondary.d/
update: update:
$(GIT) pull $(GIT) pull
@ -26,6 +28,7 @@ upgrade: install
unstall: unstall:
$(RM) -r $(DEST)/ACU/ $(RM) -r $(DEST)/ACU/
! test -d $(GITOLITE_DEST) || $(RM) -rf $(GITOLITE_DEST)/gl-pre-git
! test -d $(GITOLITE_DEST) || $(RM) -rf $(GITOLITE_DEST)/update.secondary.d ! test -d $(GITOLITE_DEST) || $(RM) -rf $(GITOLITE_DEST)/update.secondary.d
! test -d $(GITOLITE_DEST) || $(MAKEDIR) -p $(GITOLITE_DEST)/update.secondary.d ! test -d $(GITOLITE_DEST) || $(MAKEDIR) -p $(GITOLITE_DEST)/update.secondary.d

View File

@ -11,6 +11,8 @@ $ACU::Log::log_file = "/var/log/hooks/" . basename($0) . ".log";
my $ip = $1 if ($ENV{'SSH_CLIENT'} =~ m/([0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}).*/); my $ip = $1 if ($ENV{'SSH_CLIENT'} =~ m/([0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}).*/);
exit 0 if (!$ip);
log DEBUG, "Connection to $ENV{GL_REPO} from $ip"; log DEBUG, "Connection to $ENV{GL_REPO} from $ip";
# First, check if the repository is in the YYYY/ directory # First, check if the repository is in the YYYY/ directory