From 46eb7e124850f6658235c3309a4efcbb352c0e46 Mon Sep 17 00:00:00 2001 From: Jonas Smedegaard Date: Mon, 4 Oct 2010 16:40:26 +0200 Subject: Fix tidy variables in danish ikiwiki config. --- ikiwiki_da.setup | 36 ++++++++++++++---------------------- 1 file changed, 14 insertions(+), 22 deletions(-) (limited to 'ikiwiki_da.setup') diff --git a/ikiwiki_da.setup b/ikiwiki_da.setup index 1526330..24a469e 100644 --- a/ikiwiki_da.setup +++ b/ikiwiki_da.setup @@ -6,20 +6,12 @@ # # Remember to re-run ikiwiki --setup any time you edit this file. -our $libdir; -our $webdir; -our $cgidir; -our $gitdir; -our $webhost; -our $githost; -our $gitrepo; +our ($basedir, $builddir, $domain, $gitrepo); BEGIN { - $libdir = $ENV{'PWD'} . '/perl'; - $webdir = 'build/html'; - $cgidir = 'build/cgi'; - $gitdir = 'build/git'; - $webhost = 'wiki.example.org'; - $githost = 'git.example.org'; + # git hook requires full path as basedir: $ENV{'HOME'} . '/mywiki' + $basedir = $ENV{'PWD'}; + $builddir = $ENV{'BUILDDIR'} || $basedir . '/build'; + $domain = 'example.org'; $gitrepo = 'wiki'; } @@ -27,7 +19,7 @@ use IkiWiki::Setup::Standard { # name of the wiki wikiname => 'MyWiki', # contact email for wiki - #adminemail => 'me@example.org', + #adminemail => 'me@' . $domain, # users who are wiki admins adminuser => [], # users who are banned from the wiki @@ -35,13 +27,13 @@ use IkiWiki::Setup::Standard { # where the source of the wiki is located srcdir => $basedir . '/content_dummy_da', # where to build the wiki - destdir => $webdir, + destdir => $builddir . '/html', # base url to the wiki - url => 'http://' . $webhost . '/', + url => 'http://wiki.' . $domain . '/', # url to the ikiwiki.cgi - cgiurl => 'http://' . $webhost . '/ikiwiki.da.cgi', + cgiurl => 'http://wiki.' . $domain . '/ikiwiki.da.cgi', # cgi wrapper to generate - cgi_wrapper => $cgidir . '/ikiwiki.da.cgi', + cgi_wrapper => $builddir . '/cgi/ikiwiki.da.cgi', # mode for cgi_wrapper (can safely be made suid) cgi_wrappermode => '00755', # rcs backend to use @@ -54,10 +46,10 @@ use IkiWiki::Setup::Standard { editpage }], # location of template files - templatedir => 'templates_da', + templatedir => $basedir . '/templates_da', # base wiki source location underlaydirs => [ - $basedir . '/content_da', + $basedir . '/content', ], underlaydir => $basedir . '/basewiki_da', # display verbose messages when building? @@ -91,7 +83,7 @@ use IkiWiki::Setup::Standard { # force ikiwiki to use a particular umask #umask => 022, # extra library and plugin directory - libdir => $libdir, + libdir => $basedir . '/perl', # environment variables ENV => {}, # regexp of source files to ignore @@ -153,7 +145,7 @@ use IkiWiki::Setup::Standard { # gitweb url to show file history ([[file]] substituted) #historyurl => 'http://source.' . $domain . '/gitweb.cgi?p=' . $gitrepo . '.git;a=history;f=[[file]];hb=master-da', # gitweb url to show a diff ([[sha1_to]], [[sha1_from]], [[sha1_parent]], and [[file]] substituted) - #diffurl => 'http://' . $githost . '/gitweb.cgi?p=' . $gitrepo . '.git;a=blobdiff;h=[[sha1_to]];hp=[[sha1_from]];hb=[[sha1_parent]];f=[[file]]', + #diffurl => 'http://source.' . $domain . '/gitweb.cgi?p=' . $gitrepo . '.git;a=blobdiff;h=[[sha1_to]];hp=[[sha1_from]];hb=[[sha1_parent]];f=[[file]]', # where to pull and push changes (set to empty string to disable) #gitorigin_branch => 'samplewiki', # branch that the wiki is stored in -- cgit v1.2.3