From 690446b534a1d88b64030cb300f0178b4680b0d8 Mon Sep 17 00:00:00 2001 From: slotThe Date: Mon, 3 Feb 2020 10:00:52 +0100 Subject: Update changelog and readme --- changelog.md | 3 +++ readme.md | 18 ++++++++++++++---- src/Xmobar/Plugins/Monitors/Weather.hs | 2 -- 3 files changed, 17 insertions(+), 6 deletions(-) diff --git a/changelog.md b/changelog.md index 9f7f0c6..62a3413 100644 --- a/changelog.md +++ b/changelog.md @@ -14,6 +14,9 @@ _New features_ `offString` (thanks to *slotThe*). - `Battery` and `BatteryN` now support FreeBSD (thanks to Dhananjay Balan). + - New option `--useManager` for `Weather` and `UVMeter` to decide whether to + use one single manager per monitor for managing network connections or + create a new one every time a connection is made. ## Version 0.32 (December, 2019) diff --git a/readme.md b/readme.md index 1b97a4a..eb14023 100644 --- a/readme.md +++ b/readme.md @@ -740,6 +740,11 @@ something like: variable is not reported. - short option: `-w` - Default: "" + - `--useManager` _bool_ : Whether to use one single manager per monitor for + managing network connections or create a new one every time a connection is + made. + - Short option: `-m` + - Default: True - Variables that can be used with the `-t`/`--template` argument: `station`, `stationState`, `year`, `month`, `day`, `hour`, `windCardinal`, `windAzimuth`, `windMph`, `windKnots`, `windMs`, `windKmh` @@ -1414,9 +1419,14 @@ following differences: ### `UVMeter` -- Aliases to "uv " + station id. For example: `%uv brisbane%` or `%uv - alice springs%` -- Args: default monitor arguments. +- Aliases to "uv " + station id. For example: `%uv Brisbane%` or `%uv + Alice Springs%` +- Args: default monitor arguments, plus: + - `--useManager` _bool_ : Whether to use one single manager per monitor for + managing network connections or create a new one every time a connection is + made. + - Short option: `-m` + - Default: True - *Reminder:* Keep the refresh rate high, to avoid making unnecessary requests every time the plug-in is run. @@ -1424,7 +1434,7 @@ following differences: http://www.arpansa.gov.au/uvindex/realtime/xml/uvvalues.xml - Example: - Run UVMeter "brisbane" ["-H", "3", "-L", "3", "--low", "green", "--high", "red"] 900 + Run UVMeter "Brisbane" ["-H", "3", "-L", "3", "--low", "green", "--high", "red"] 900 ## Executing External Commands diff --git a/src/Xmobar/Plugins/Monitors/Weather.hs b/src/Xmobar/Plugins/Monitors/Weather.hs index 9c62288..f9c9f39 100644 --- a/src/Xmobar/Plugins/Monitors/Weather.hs +++ b/src/Xmobar/Plugins/Monitors/Weather.hs @@ -25,8 +25,6 @@ import Data.Maybe (fromMaybe) import Network.HTTP.Conduit import Network.HTTP.Types.Status import Network.HTTP.Types.Method -import qualified Data.ByteString.Lazy.Char8 as B -import Data.Char (toLower) import Text.ParserCombinators.Parsec import System.Console.GetOpt (ArgDescr(ReqArg), OptDescr(Option)) -- cgit v1.2.3