Add /etc/weather/weatherrc to config search.
authorJeremy Stanley <fungi@yuggoth.org>
Thu, 30 Aug 2012 11:13:57 +0000 (11:13 +0000)
committerJeremy Stanley <fungi@yuggoth.org>
Thu, 30 Aug 2012 11:13:57 +0000 (11:13 +0000)
* weather.1(INPUT FILES): Updated the list of potential weatherrc
locations to reflect those mentioned in the INSTALL file, particularly
the addition of /etc/weather/weatherrc in the 2.0 release.

* weather.py(get_config): Adjusted the configuration search locations to
include /etc/weather/weatherrc, since the INSTALL file started
mentioning it in the 2.0 release even though it wasn't actually
implemented as pointed out by Ben Kohler.

weather.1
weather.py

index 7321ff5..454273e 100644 (file)
--- a/weather.1
+++ b/weather.1
@@ -201,7 +201,7 @@ The file format and configuration options are described in
 .
 They are aggregated in the following order:
 .TP
-.I /etc/weatherrc
+.I /etc/weatherrc " or " /etc/weather/weatherrc
 the system-wide configuration
 .TP
 .IR ~/.weather/weatherrc " or " ~/.weatherrc
index 54d68f5..60067f2 100644 (file)
@@ -609,6 +609,7 @@ def get_config():
     import os
     rcfiles = [
         "/etc/weatherrc",
+        "/etc/weather/weatherrc",
         os.path.expanduser("~/.weather/weatherrc"),
         os.path.expanduser("~/.weatherrc"),
         "weatherrc"