bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#25559: Trouble getting battery status


From: Lars Ingebrigtsen
Subject: bug#25559: Trouble getting battery status
Date: Fri, 23 Aug 2019 02:41:47 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

Lars Ingebrigtsen <address@hidden> writes:

> It looks like it just looks for batteries named BATx:
>
> (defcustom battery-linux-sysfs-regexp "[bB][aA][tT][0-9]?$"
>
> That seems unnecessary -- surely we can just look into all the
> directories there and see whether it looks like we have a battery
> directory?  The patch below does this, but perhaps it's problematic.  Do
> all power_supply/<battery> directories have a "capacity" file, or does
> that vary by Linux kernel version?

There were no comments, and I've tested the patch on three different
GNU/Linux systems, and it seems to work OK.  But like I said, I'm not
extremely confident about this change -- if this leads to problems,
feel free to revert.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





reply via email to

[Prev in Thread] Current Thread [Next in Thread]