X-Git-Url: https://git.cweiske.de/phorkie.git/blobdiff_plain/8d29b8e073c9a3795ad7ededf4cb5e8683102162..808a3a5857c77ef99605fdfdde9b31b5c02e22c6:/src/phorkie/Repository/Setup.php diff --git a/src/phorkie/Repository/Setup.php b/src/phorkie/Repository/Setup.php index e26338b..43a8500 100644 --- a/src/phorkie/Repository/Setup.php +++ b/src/phorkie/Repository/Setup.php @@ -24,6 +24,30 @@ class Repository_Setup unlink($hookfile); } touch($this->repo->gitDir . '/git-daemon-export-ok'); + + $vc = $this->repo->getVc(); + + file_put_contents( + $this->repo->gitDir . '/hooks/post-update', + <<repo->gitDir . '/hooks/post-update', 0755); + + //keep track of owner + $vc->getCommand('config') + ->addArgument('owner.name') + ->addArgument($_SESSION['name']) + ->execute(); + $vc->getCommand('config') + ->addArgument('owner.email') + ->addArgument($_SESSION['email']) + ->execute(); } }