ENV can be used in the setup file to override environment variable setting, such...
authorJoey Hess <joey@kodama.kitenet.net>
Thu, 15 May 2008 22:20:52 +0000 (18:20 -0400)
committerJoey Hess <joey@kodama.kitenet.net>
Thu, 15 May 2008 22:20:52 +0000 (18:20 -0400)
IkiWiki.pm
debian/changelog
doc/ikiwiki.setup
doc/todo/configurable_timezones.mdwn

index 88407584fbf7f8f2b3c51de7a6cfd16df57626be..7e64518b313c4c73445974bf45c875739a483464 100644 (file)
@@ -103,6 +103,12 @@ sub checkconfig () { #{{{
                }
        }
 
+       if (ref $config{ENV} eq 'HASH') {
+               foreach my $val (keys %{$config{ENV}}) {
+                       $ENV{$val}=$config{ENV}{$val};
+               }
+       }
+
        if ($config{w3mmode}) {
                eval q{use Cwd q{abs_path}};
                error($@) if $@;
index df09e91c580a5974db1fa95dcfef9ae8dc4950ed..6e8e550df2d29b041874094960d0ed3c58d8a7dd 100644 (file)
@@ -11,6 +11,8 @@ ikiwiki (2.47) UNRELEASED; urgency=low
     it just expanded to nothing.
   * git: Skip over signed-off-by and similar lines in commit messages
     when generating recentchanges.
+  * ENV can be used in the setup file to override environment variable
+    setting, such as TZ or PATH.
 
  -- Joey Hess <joeyh@debian.org>  Tue, 13 May 2008 12:30:18 -0400
 
index 7813eb822e2ac8788c1bff27343cfca16deff05d..3d3c2a7f66896ed94b5a63169b460ec30eb81cfb 100644 (file)
@@ -143,6 +143,12 @@ use IkiWiki::Setup::Standard {
        #disable_plugins => [qw{inline htmlscrubber passwordauth openid}],
        # To add a directory to the perl search path, use this.
        #libdir => "/home/me/.ikiwiki/",
+       
+       # To override environment variable settings, you can list values here.
+       #ENV => {
+       #       TZ => "America/New_York",
+       #       PATH => "/home/me/bin:/usr/local/bin:/usr/bin:/bin",
+       #},
 
        # For use with the tag plugin, make all tags be located under a
        # base page.
index 594cc0f1fc96f2023b2819443f02b61bfe061698..3ed50503a61bd00c51e23d8e39bc23eff18f6bb4 100644 (file)
@@ -1,3 +1,5 @@
 It would be nice if the sure could set the timezone of the wiki, and have ikiwiki render the pages with that timezone.
 
 This is nice for shared hosting, and other situation where the user doesn't have control over the server timezone.
+
+> [[done]] via the ENV setting in the setup file. --[[Joey]]