Skip to content

Instantly share code, notes, and snippets.

@lordofwizard
Created November 30, 2022 16:09
Show Gist options
  • Save lordofwizard/db0f515289c7b76f614986cbc15ee4d7 to your computer and use it in GitHub Desktop.
Save lordofwizard/db0f515289c7b76f614986cbc15ee4d7 to your computer and use it in GitHub Desktop.
My Basic Implementation of a Brighness setting script
#!/bin/sh
#Just a simple brightness changing script
# Requires the program brightnessctl program to be installed
current_btr=$(brightnessctl g)
command=$1
if [ "$command" == "up" ]; then
brightnessctl s $(($current_btr + 10))
elif [ "$command" == "down" ]; then
brightnessctl s $(($current_btr - 10))
fi
notify-send "Brightness set to ..." $(brightnessctl g)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment