2 $pharFile = \Phar::running();
4 $phorkieDir = __DIR__ . '/../';
6 //remove phar:// from the path
7 $phorkieDir = dirname(substr($pharFile, 7)) . '/';
10 $GLOBALS['phorkie']['cfg'] = array(
12 'gitdir' => $phorkieDir . 'repos/git/',
13 'workdir' => $phorkieDir . 'repos/work/',
14 'tpl' => __DIR__ . '/templates/',
18 'iconpng' => '',//phorkie browser icon (favicon)
22 'elasticsearch' => null,
23 'index' => 'new',//"new" or "list"
25 'defaultListPage' => 'last',//a number or "last"
26 'notificator' => array(
27 /* send out pingback/webmentions when a remote paste is forked */
30 /* array of urls that get called when
31 a paste is created, edited or deleted */
35 $GLOBALS['phorkie']['auth'] = array(
36 // 0 = public, no authentication, 1 = protect adds/edits/deletes,
37 // 2 = require authentication
39 'listedUsersOnly' => false,
40 'users' => array(), // Array of OpenIDs that may login
41 'anonymousName' => 'Anonymous', // Email for non-authenticated commits
42 'anonymousEmail' => 'anonymous@phorkie', // Email for non-authenticated commits
44 $GLOBALS['phorkie']['tools'] = array(
45 '\\phorkie\\Tool_Xmllint' => true,
46 '\\phorkie\\Tool_PHPlint' => true,
49 * Array of supported file types / languages.
50 * Key is the file extension
52 $GLOBALS['phorkie']['languages'] = array(
60 'mime' => 'text/diff',
65 'mime' => 'text/html',
70 'mime' => 'text/html',
75 'title' => 'JPEG image',
76 'mime' => 'image/jpeg',
85 'title' => 'Javascript',
86 'mime' => 'application/javascript',
87 'geshi' => 'javascript'
90 'title' => 'Javascript',
91 'mime' => 'application/javascript',
92 'geshi' => 'javascript',
96 'title' => 'Markdown',
97 'mime' => 'text/x-markdown',
98 'renderer' => '\\phorkie\\Renderer_Markdown'
102 'mime' => 'application/x-perl',
107 'mime' => 'text/x-php',
111 'title' => 'PNG image',
112 'mime' => 'image/png',
116 'title' => 'Ruby/Rails',
117 'mime' => 'text/x-ruby', /* Is this an acceptable mime type? */
121 'title' => 'reStructuredText',
122 'mime' => 'text/x-rst',
124 'renderer' => '\\phorkie\\Renderer_ReStructuredText',
127 'title' => 'Shell script (Bash)',
128 'mime' => 'text/x-shellscript',
133 'mime' => 'text/x-sql',
137 'title' => 'SVG image',
138 'mime' => 'image/svg+xml',
142 'title' => 'Text (plain)',
143 'mime' => 'text/plain',
147 'title' => 'TypoScript',
148 'mime' => 'text/x-typoscript',/* TODO: correct type */
149 'geshi' => 'typoscript'
153 'mime' => 'application/wsdl+xml',
158 'mime' => 'text/xml',
162 'title' => 'eXtensible Stylesheet Language',
163 'mime' => 'text/xml',
169 //needed for UTF-8 characters in file names
170 setlocale(LC_CTYPE, 'en_US.UTF_8');