fix git dir creation
[phorkie.git] / src / phorkie / Repository / Post.php
index 6ff8df60310e7428acc3c3d48260b03937a7e43a..f138491ac58735bc83eb61002aff455fdaf7e88c 100644 (file)
@@ -114,12 +114,11 @@ class Repository_Post
         $rs = new Repositories();
         $repo = $rs->createNew();
         $vc = $repo->getVc();
-        //$vc->initRepository();
         $vc->getCommand('init')
             //this should be setOption, but it fails with a = between name and value
             ->addArgument('--separate-git-dir')
-            ->addArgument($GLOBALS['phorkie']['cfg']['gitdir'] . '/' . $repo->id)
-            ->addArgument($repo->workDir)
+            ->addArgument($GLOBALS['phorkie']['cfg']['gitdir'] . '/' . $repo->id . '.git')
+            ->addArgument($repo->workDir);
             ->execute();
 
         foreach (glob($repo->gitDir . '/hooks/*') as $hookfile) {