I’ve been using i3 for a while now, but the xfce power manager doesn’t work outside the desktop environment, is there any alternative you can recommend? It doesn’t matter if it is a terminal based or graphical interface program, I just need something that can suspend the computer after a certain time or lock it when the laptop is closed

You are viewing a single thread.
View all comments View context
2 points
*

Also adding auto-cpufreq, ryzenadj, tuned.

But this depends on your CPU used.

TLP is good, tuned may be better?

TLP has a common USB lost issue, that is mitigated by disabling USB-autosuspend in the config. TLP config is found here

And if you need a tool for warning about AC disconnect, you can use a systemd service.

cat > /usr/local/bin/check_ac.sh <<EOF
#!/bin/bash

while true; do
    if [[ "$(cat /sys/class/power_supply/AC/online)" -eq 0 ]]; then
        notify-send -t 20 -a "Power" "AC Disconnected"
    fi
		sleep 20
done
EOF
chmod +x /usr/local/bin/check_ac.sh
cat > /etc/systemd/user/ac-warning.service <<EOF
[Unit]
Description=Monitor AC State and Notify

[Service]
ExecStart=/usr/local/bin/check_ac.sh
Restart=always

[Install]
WantedBy=graphical.target
EOF
systemctl --user daemon-reload
systemctl --user enable --now ac-warning.service
permalink
report
parent
reply

Linux

!linux@lemmy.ml

Create post

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word “Linux” in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

  • Posts must be relevant to operating systems running the Linux kernel. GNU/Linux or otherwise.
  • No misinformation
  • No NSFW content
  • No hate speech, bigotry, etc

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

Community stats

  • 7.9K

    Monthly active users

  • 6.3K

    Posts

  • 175K

    Comments