diff options
author | joey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071> | 2006-12-19 16:58:55 +0000 |
---|---|---|
committer | joey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071> | 2006-12-19 16:58:55 +0000 |
commit | 389ad222ec2e0457106339fb71713dad7b95f80e (patch) | |
tree | 0012a3aaacf6e8823dd3abe5e2c62ded51845660 | |
parent | 9e1c79e58824814eb3de721176813ea79cbc518c (diff) |
* Add userdir config setting.
-rw-r--r-- | IkiWiki.pm | 1 | ||||
-rw-r--r-- | IkiWiki/CGI.pm | 4 | ||||
-rw-r--r-- | debian/changelog | 3 | ||||
-rw-r--r-- | doc/ikiwiki.setup | 2 | ||||
-rw-r--r-- | doc/usage.mdwn | 6 |
5 files changed, 14 insertions, 2 deletions
diff --git a/IkiWiki.pm b/IkiWiki.pm index 45a3627cc..4869b3ef3 100644 --- a/IkiWiki.pm +++ b/IkiWiki.pm @@ -67,6 +67,7 @@ sub defaultconfig () { #{{{ locale => undef, sslcookie => 0, httpauth => 0, + userdir => "", } #}}} sub checkconfig () { #{{{ diff --git a/IkiWiki/CGI.pm b/IkiWiki/CGI.pm index d00de740a..9b5ee6c19 100644 --- a/IkiWiki/CGI.pm +++ b/IkiWiki/CGI.pm @@ -666,7 +666,9 @@ sub userlink ($) { #{{{ return "<a href=\"$user\">".escapeHTML($display)."</a>"; } else { - return htmllink("", "", escapeHTML($user), 1); + return htmllink("", "", escapeHTML( + length $config{userdir} ? $config{userdir}."/".$user : $user + ), 1); } } #}}} diff --git a/debian/changelog b/debian/changelog index e37def28c..fda813c87 100644 --- a/debian/changelog +++ b/debian/changelog @@ -3,8 +3,9 @@ ikiwiki (1.36) UNRELEASED; urgency=low * Fix various links on the hyperestradier pages. * Use POST for poll to avoid some robots. * Fix sometimes broken links to Discussion pages from blog pages. + * Add userdir config setting. - -- Joey Hess <joeyh@debian.org> Thu, 14 Dec 2006 14:41:01 -0500 + -- Joey Hess <joeyh@debian.org> Tue, 19 Dec 2006 11:58:44 -0500 ikiwiki (1.35) unstable; urgency=low diff --git a/doc/ikiwiki.setup b/doc/ikiwiki.setup index f7bf81bc9..d23010fd5 100644 --- a/doc/ikiwiki.setup +++ b/doc/ikiwiki.setup @@ -91,6 +91,8 @@ use IkiWiki::Setup::Standard { # Logging settings: verbose => 0, syslog => 0, + # To link to user pages in a subdirectory of the wiki. + #userdir => "users", # To add plugins, list them here. #add_plugins => [qw{goodstuff openid search wikitext camelcase diff --git a/doc/usage.mdwn b/doc/usage.mdwn index 9e260adc2..ce60d91a4 100644 --- a/doc/usage.mdwn +++ b/doc/usage.mdwn @@ -228,6 +228,12 @@ configuration options of their own. Enables or disables "Discussion" links from being added to the header of every page. The links are enabled by default. +* --userdir subdir + + Optionally, allows links to users of the wiki to link to pages inside a + subdirectory of the wiki. The default is to link to pages in the toplevel + directory of the wiki. + * --timeformat format Specify how to display the time or date. The format string is passed to the |