Disclaimer: this is a bit of a repost, but I thought I might share the experience so that others have an easier time finding the solution.
So, yesterday I learned something interesting about sudoers rules precedence.
I wanted to make a script that detected the current status of tlp to display it in waybar, and for that I needed to execute tlp-stat as root. Because it’s a script that is executed every 10 seconds or so I can’t have sudo asking for my password every single time, so I added a sudoers rule.
Continue reading