Skip to content
Snippets Groups Projects
Commit 4a9a52be authored by Andreas Gohr's avatar Andreas Gohr
Browse files

Local configuration files #349

Local configs can now be added to the following files to make
updating simpler:

acronyms.local.conf
mime.local.conf
smileys.local.conf
entities.local.conf
interwiki.local.conf

darcs-hash:20050723204824-7ad00-18b8e238f41bce4d3ac25c89bff5b9abf33620f4.gz
parent d2ee49ce
No related branches found
No related tags found
No related merge requests found
......@@ -37,6 +37,10 @@ function getMimeTypes() {
static $mime = NULL;
if ( !$mime ) {
$mime = confToHash(DOKU_INC . 'conf/mime.conf');
if (@file_exists(DOKU_INC . 'conf/mime.local.conf')) {
$local = confToHash(DOKU_INC . 'conf/mime.local.conf');
$mime = array_merge($mime, $local);
}
}
return $mime;
}
......@@ -50,8 +54,8 @@ function getAcronyms() {
static $acronyms = NULL;
if ( !$acronyms ) {
$acronyms = confToHash(DOKU_INC . 'conf/acronyms.conf');
if (@file_exists(DOKU_INC . 'conf/local.acronyms.conf')) {
$local = confToHash(DOKU_INC . 'conf/local.acronyms.conf');
if (@file_exists(DOKU_INC . 'conf/acronyms.local.conf')) {
$local = confToHash(DOKU_INC . 'conf/acronyms.local.conf');
$acronyms = array_merge($acronyms, $local);
}
}
......@@ -67,6 +71,10 @@ function getSmileys() {
static $smileys = NULL;
if ( !$smileys ) {
$smileys = confToHash(DOKU_INC . 'conf/smileys.conf');
if (@file_exists(DOKU_INC . 'conf/smileys.local.conf')) {
$local = confToHash(DOKU_INC . 'conf/smileys.local.conf');
$smileys = array_merge($smileys, $local);
}
}
return $smileys;
}
......@@ -80,6 +88,10 @@ function getEntities() {
static $entities = NULL;
if ( !$entities ) {
$entities = confToHash(DOKU_INC . 'conf/entities.conf');
if (@file_exists(DOKU_INC . 'conf/entities.local.conf')) {
$local = confToHash(DOKU_INC . 'conf/entities.local.conf');
$entities = array_merge($entities, $local);
}
}
return $entities;
}
......@@ -93,6 +105,10 @@ function getInterwiki() {
static $wikis = NULL;
if ( !$wikis ) {
$wikis = confToHash(DOKU_INC . 'conf/interwiki.conf',true);
if (@file_exists(DOKU_INC . 'conf/interwiki.local.conf')) {
$local = confToHash(DOKU_INC . 'conf/interwiki.local.conf');
$wikis = array_merge($wikis, $local);
}
}
//add sepecial case 'this'
$wikis['this'] = DOKU_URL.'{NAME}';
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment