summaryrefslogtreecommitdiffhomepage
path: root/Plugins/Monitors/Net.hs
diff options
context:
space:
mode:
Diffstat (limited to 'Plugins/Monitors/Net.hs')
-rw-r--r--Plugins/Monitors/Net.hs6
1 files changed, 4 insertions, 2 deletions
diff --git a/Plugins/Monitors/Net.hs b/Plugins/Monitors/Net.hs
index b17aa44..d9cd534 100644
--- a/Plugins/Monitors/Net.hs
+++ b/Plugins/Monitors/Net.hs
@@ -12,7 +12,7 @@
--
-----------------------------------------------------------------------------
-module Plugins.Monitors.Net where
+module Plugins.Monitors.Net (netConfig, runNet) where
import Plugins.Monitors.Common
import qualified Data.ByteString.Lazy.Char8 as B
@@ -64,8 +64,10 @@ netParser =
formatNet :: Float -> Monitor (String, String)
formatNet d = do
+ s <- getConfigValue useSuffix
+ let str = if s then (++"Kb/s") . showDigits 1 else showDigits 1
b <- showLogBar 0.9 d
- x <- showWithColors (showDigits 1) d
+ x <- showWithColors str d
return (x, b)
printNet :: NetDev -> Monitor String