Imported from archive.
* Release 1.4. * (all): Updated the copyright years for 2008 on some of the files in the current release and added a copyright statement to any files previously lacking one. * LICENSE: Replaced the previous BSD-like license with the one used by the OpenBSD project (modeled after the Internet Software Consortium's, a two-clause BSD license removing language made unnecessary by the Berne convention); this new license is functionally identical to the old one, just more terse and openly recognized. * weather: Clarified function parameters in calls from the wrapper script to ease future ABI changes in the underlying module. * weather, weather.py: Some extra comments were added to the source, indentation style was updated from tab characters to three-space, and lines longer than 79 columns were refactored or otherwise split. * weather.1, weather.5, weather.py: Added an flines option to allow the maximum number of forecast output lines to be shortened. Added furl and murl options to allow overriding of the default current conditions and forecast data retrieval URLs. Added a headers option to allow overriding the default list of header names for current conditions data filtering. Added a quiet option to suppress the preamble lines and indentation for both current conditions and forecast output. * weather.py: Replaced the hardcoded fallback default METAR station ID and forecast city/state abbreviation with error messages to minimize confusion when necessary values are omitted. Adjusted a couple of hard-coded error message strings to be consistent with the output format of the option_parser module. Switched from urllib to urllib2 for retrieving data, providing a simpler means to detect and report retrieval errors. Upped the version to 1.4.
This commit is contained in:
39
weatherrc.5
39
weatherrc.5
@@ -1,6 +1,8 @@
|
||||
.TH WEATHERRC 5 "March 26, 2006" "" \" -*- nroff -*-
|
||||
\" Copyright (c) 2006 Jeremy Stanley <fungi@yuggoth.org>, all rights reserved.
|
||||
\" Licensed per terms in the LICENSE file distributed with this software.
|
||||
.TH WEATHERRC 5 "July 13, 2008" "" \" -*- nroff -*-
|
||||
\" Copyright (c) 2006-2008 Jeremy Stanley <fungi@yuggoth.org>.
|
||||
\" Permission to use, copy, modify, and distribute this software is
|
||||
\" granted under terms provided in the LICENSE file distributed with
|
||||
\" this software.
|
||||
.SH NAME
|
||||
weatherrc \- configuration file format for the
|
||||
.BR weather (1)
|
||||
@@ -20,20 +22,47 @@ These parameters are supported...
|
||||
.B city
|
||||
the city name (ex: Raleigh Durham)
|
||||
.TP
|
||||
.B conditions
|
||||
output current conditions (possible values are False and True or 0 and 1)
|
||||
.TP
|
||||
.B flines
|
||||
maximum number of forecast lines to show (integer value, 0 means unlimited)
|
||||
.TP
|
||||
.B forecast
|
||||
include a local forecast (possible values are False and True or 0 and 1)
|
||||
.TP
|
||||
.B furl
|
||||
forecast URL (ex: http://forecast.org/%st%/%city%.txt)
|
||||
.TP
|
||||
.B headers
|
||||
the conditions headers to display (ex: temperature,wind)
|
||||
.TP
|
||||
.B id
|
||||
the METAR station ID (ex: KRDU)
|
||||
.TP
|
||||
.B conditions
|
||||
output current conditions (possible values are False and True or 0 and 1)
|
||||
.B murl
|
||||
METAR URL (ex: http://metar.org/%id%.txt)
|
||||
.TP
|
||||
.B quiet
|
||||
skip preambles and don't indent (possible values are False and True or 0 and 1)
|
||||
.TP
|
||||
.B st
|
||||
the state abbreviation (ex: NC)
|
||||
.TP
|
||||
.B verbose
|
||||
show full decoded feeds (possible values are False and True or 0 and 1)
|
||||
.SH URL FORMAT
|
||||
The placeholders %city% and %st% in the furl URL and %id% in the murl URL
|
||||
will be replaced with the city, st and id definitions respectively. If the
|
||||
placeholder has all letters lowercased, the replacement will be forced to
|
||||
all lowercase. If the placeholder has all letters uppercased, the
|
||||
replacement will be forced to all uppercase. If the placeholder has its
|
||||
first letter uppercased and the remainder lowercased, then all words in the
|
||||
replacement will start with an uppercase letter and the rest will be
|
||||
lowercase. If the placeholder has its last letter uppercased and the
|
||||
remainder lowercased, then case will be preserved in the replacement. Also,
|
||||
after replacement, any spaces in the resulting URL will be converted to
|
||||
underscore characters prior to use.
|
||||
.SH EXAMPLES
|
||||
Following is an example
|
||||
.B ~/.weatherrc
|
||||
|
||||
Reference in New Issue
Block a user