Skip to content
This repository has been archived by the owner on Sep 8, 2020. It is now read-only.

Linux: fixes sysfs battery discovery #946

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

smattie
Copy link

@smattie smattie commented Sep 7, 2019

Removes the assumption that batteries are found in /sys/class/power_supply/BAT?/ and instead reads from /sys/class/power_supply/*/type

@natoscott
Copy link
Collaborator

Merged here: htop-dev/htop@cdff8ae

Explorer09 pushed a commit to Explorer09/htop that referenced this pull request Feb 25, 2022
When we run a process which utilizes CPU between 100.0% and 999.9%, htop
shows an unnecessary decimal character at the end of the value. For
example, '100.x' and '247.x' become '100.' and '247.' respectively.

When CPU utilization is less than and equal to '99.9%', show the result
with single digit precision and if result is less than four characters,
pad it with the blank space. When CPU utilization is greater than
'99.9%', show only integral part of the result and if it's less than
four characters, pad it with the blank space.

Closes: hishamhm#946
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants