{"action":"created","issue":{"url":"https://api.github.com/repos/jaor/xmobar/issues/276","repository_url":"https://api.github.com/repos/jaor/xmobar","labels_url":"https://api.github.com/repos/jaor/xmobar/issues/276/labels{/name}","comments_url":"https://api.github.com/repos/jaor/xmobar/issues/276/comments","events_url":"https://api.github.com/repos/jaor/xmobar/issues/276/events","html_url":"https://github.com/jaor/xmobar/issues/276","id":174581343,"number":276,"title":"Battery \"command\" always shows \"Charged\"","user":{"login":"waynr","id":1441126,"avatar_url":"https://avatars.githubusercontent.com/u/1441126?v=3","gravatar_id":"","url":"https://api.github.com/users/waynr","html_url":"https://github.com/waynr","followers_url":"https://api.github.com/users/waynr/followers","following_url":"https://api.github.com/users/waynr/following{/other_user}","gists_url":"https://api.github.com/users/waynr/gists{/gist_id}","starred_url":"https://api.github.com/users/waynr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/waynr/subscriptions","organizations_url":"https://api.github.com/users/waynr/orgs","repos_url":"https://api.github.com/users/waynr/repos","events_url":"https://api.github.com/users/waynr/events{/privacy}","received_events_url":"https://api.github.com/users/waynr/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-09-01T17:31:06Z","updated_at":"2016-09-01T17:34:28Z","closed_at":null,"body":"```bash\r\n$ cat /etc/debian_version\r\nstretch/sid\r\n```\r\n\r\n```bash\r\n$ uname -a\r\nLinux pathways 4.6.3 #1 SMP Tue Jun 28 12:32:12 PDT 2016 x86_64 GNU/Linux\r\n```\r\n\r\nVersions and stuff:\r\n\r\nsoftware | version\r\n-------------- | ----------\r\nxmonad | 0.12-3+b1\r\nlibghc-xmonad-dev | 0.12-3+b1\r\nlibghc-xmonad-contrib-dev | 0.12-1+b1\r\nxmobar | 0.24-1\r\n\r\n\r\n```haskell\r\n-- vim: ts=4 sts=4 sw=4 expandtab\r\n\r\nConfig { font = \"xft:Proggy Fonts:size=8:antialias=true\"\r\n       , bgColor = \"black\"\r\n       , fgColor = \"white\"\r\n       , position = TopW L 95\r\n       , sepChar = \"%\"\r\n       , alignSep = \"}{\"\r\n       , template = \"%StdinReader% }{ <fc=#858585>%battery%</fc> | <fc=#858585>%dynnetwork%</fc> | <fc=#858585>%coretemp%</fc> | <fc=#858585>%multicpu%</fc> | <fc=#858585>%memory%</fc> | <fc=#ee9a00>%date%</fc>\"\r\n\r\n       , allDesktops = True,\r\n       , commands = [\r\n        -- network activity monitor (dynamic interface resolution)\r\n        Run DynNetwork     [ \"--template\" , \"<dev>: <tx>kB/s <rx>kB/s\"\r\n                             , \"--Low\"      , \"1000\"       -- units: kB/s\r\n                             , \"--High\"     , \"5000\"       -- units: kB/s\r\n                             , \"--low\"      , \"green\"\r\n                             , \"--normal\"   , \"darkorange\"\r\n                             , \"--high\"     , \"darkred\"\r\n                             ] 2\r\n\r\n        -- cpu activity monitor\r\n        , Run MultiCpu       [ \"--template\" , \"Cpu: <total0>% <total1>%\"\r\n                             , \"--Low\"      , \"50\"         -- units: %\r\n                             , \"--High\"     , \"85\"         -- units: %\r\n                             , \"--low\"      , \"green\"\r\n                             , \"--normal\"   , \"darkorange\"\r\n                             , \"--high\"     , \"darkred\"\r\n                             ] 10\r\n\r\n        -- cpu core temperature monitor\r\n        , Run CoreTemp       [ \"--template\" , \"Temp: <core0>°C <core1>°C\"\r\n                             , \"--Low\"      , \"70\"        -- units: °C\r\n                             , \"--High\"     , \"80\"        -- units: °C\r\n                             , \"--low\"      , \"green\"\r\n                             , \"--normal\"   , \"darkorange\"\r\n                             , \"--high\"     , \"darkred\"\r\n                             ] 60\r\n\r\n        -- memory usage monitor\r\n        , Run Memory         [ \"--template\" ,\"Mem: <usedratio>%\"\r\n                             , \"--Low\"      , \"20\"        -- units: %\r\n                             , \"--High\"     , \"90\"        -- units: %\r\n                             , \"--low\"      , \"green\"\r\n                             , \"--normal\"   , \"darkorange\"\r\n                             , \"--high\"     , \"darkred\"\r\n                             ] 30\r\n\r\n        -- battery monitor\r\n        , Run Battery        [ \"--template\" , \"Batt: <acstatus>\"\r\n                             , \"--Low\"      , \"50\"        -- units: %\r\n                             , \"--High\"     , \"90\"        -- units: %\r\n                             , \"--low\"      , \"darkred\"\r\n                             , \"--normal\"   , \"darkorange\"\r\n                             , \"--high\"     , \"green\"\r\n\r\n                             , \"--\" -- battery specific options\r\n                                       -- discharging status\r\n                                       , \"-o\" , \"<left>% (<timeleft>)\"\r\n                                       -- AC \"on\" status\r\n                                       , \"-O\" , \"<fc=#dAA520>Charging</fc>\"\r\n                                       -- charged status\r\n                                       , \"-i\" , \"<fc=#00C000>Charged</fc>\"\r\n                             ] 60\r\n        -- time and date indicator \r\n        --   (%F = y-m-d date, %a = day of week, %T = h:m:s time)\r\n        , Run Date           \"<fc=#009BFB>%F (%a) %T</fc>\" \"date\" 10\r\n\r\n        , Run StdinReader\r\n        ]\r\n       }\r\n```\r\n\r\n```bash\r\n$ acpi\r\nBattery 0: Discharging, 70%, 03:15:09 remaining\r\n```"},"comment":{"url":"https://api.github.com/repos/jaor/xmobar/issues/comments/244153077","html_url":"https://github.com/jaor/xmobar/issues/276#issuecomment-244153077","issue_url":"https://api.github.com/repos/jaor/xmobar/issues/276","id":244153077,"user":{"login":"waynr","id":1441126,"avatar_url":"https://avatars.githubusercontent.com/u/1441126?v=3","gravatar_id":"","url":"https://api.github.com/users/waynr","html_url":"https://github.com/waynr","followers_url":"https://api.github.com/users/waynr/followers","following_url":"https://api.github.com/users/waynr/following{/other_user}","gists_url":"https://api.github.com/users/waynr/gists{/gist_id}","starred_url":"https://api.github.com/users/waynr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/waynr/subscriptions","organizations_url":"https://api.github.com/users/waynr/orgs","repos_url":"https://api.github.com/users/waynr/repos","events_url":"https://api.github.com/users/waynr/events{/privacy}","received_events_url":"https://api.github.com/users/waynr/received_events","type":"User","site_admin":false},"created_at":"2016-09-01T17:34:28Z","updated_at":"2016-09-01T17:34:28Z","body":"Based on discussion in #271 it looks like you might also be interested in this:\r\n```bash\r\n$ ls -l /sys/class/power_supply/BAT0/\r\ntotal 0\r\n-rw-r--r-- 1 root root 4096 Sep  1 10:34 alarm\r\n-r--r--r-- 1 root root 4096 Sep  1 10:34 capacity\r\n-r--r--r-- 1 root root 4096 Sep  1 10:34 capacity_level\r\n-r--r--r-- 1 root root 4096 Sep  1 10:34 cycle_count\r\nlrwxrwxrwx 1 root root    0 Sep  1 10:34 device -> ../../../PNP0C0A:00\r\n-r--r--r-- 1 root root 4096 Sep  1 10:34 energy_full\r\n-r--r--r-- 1 root root 4096 Sep  1 10:34 energy_full_design\r\n-r--r--r-- 1 root root 4096 Sep  1 10:34 energy_now\r\n-r--r--r-- 1 root root 4096 Sep  1 10:34 manufacturer\r\n-r--r--r-- 1 root root 4096 Sep  1 10:34 model_name\r\ndrwxr-xr-x 2 root root    0 Sep  1 10:34 power\r\n-r--r--r-- 1 root root 4096 Sep  1 10:34 power_now\r\n-r--r--r-- 1 root root 4096 Sep  1 10:34 present\r\n-r--r--r-- 1 root root 4096 Sep  1 10:34 serial_number\r\n-r--r--r-- 1 root root 4096 Sep  1 10:34 status\r\nlrwxrwxrwx 1 root root    0 Sep  1 10:34 subsystem -> ../../../../../../../../../class/power_supply\r\n-r--r--r-- 1 root root 4096 Sep  1 10:34 technology\r\n-r--r--r-- 1 root root 4096 Sep  1 10:34 type\r\n-rw-r--r-- 1 root root 4096 Sep  1 10:34 uevent\r\n-r--r--r-- 1 root root 4096 Sep  1 10:34 voltage_min_design\r\n-r--r--r-- 1 root root 4096 Sep  1 10:34 voltage_now\r\n```"}}
{"actor":{"display_login":"waynr"}}