Merge remote-tracking branch 'origin/master'
[phorkie.git] / data / config.default.php
index 2beb3549568693a9d4634cef92af31ea9c163074..2e588fadc39fb8a93a68bfade175f5285d899e6d 100644 (file)
@@ -1,10 +1,18 @@
 <?php
+$pharFile = \Phar::running();
+if ($pharFile == '') {
+    $phorkieDir = __DIR__ . '/../';
+} else {
+    //remove phar:// from the path
+    $phorkieDir = dirname(substr($pharFile, 7)) . '/';
+}
+
 $GLOBALS['phorkie']['cfg'] = array(
     'debug'         => false,
-    'gitdir'        => __DIR__ . '/../repos/git/',
-    'workdir'       => __DIR__ . '/../repos/work/',
+    'gitdir'        => $phorkieDir . 'repos/git/',
+    'workdir'       => $phorkieDir . 'repos/work/',
     'tpl'           => __DIR__ . '/templates/',
-    'baseurl'       => '/',
+    'baseurl'       => null,
     'avatars'       => true,
     'css'           => '',
     'iconpng'       => '',//phorkie browser icon (favicon)