Added the bri / vol scripts!

This commit is contained in:
kirreen 2024-10-11 21:25:46 +02:00
parent 3841c491b0
commit b453e61e60
2 changed files with 22 additions and 0 deletions

12
home/.bin/bri Executable file
View file

@ -0,0 +1,12 @@
#!/usr/bin/env zsh
if \[ "$1" = "--up" \]; then
# eww -c $HOME/.dotfiles/eww/bar o bri && brightnessctl -q s 5%+ && sleep 3 && eww -c $HOME/.dotfiles/eww/bar c bri
swayosd-client --brightness raise
# brightnessctl -q s 5%+
elif \[ "$1" = "--down" \]; then
# eww -c $HOME/.dotfiles/eww/bar o bri && brightnessctl -q s 5%- && sleep 3 && eww -c $HOME/.dotfiles/eww/bar c bri
swayosd-client --brightness lower
# brightnessctl -q s 5%-
elif \[ "$1" = "--get" \]; then
echo $(brightnessctl | head -n 2 | tail -n 1 | awk '{print $4}' | tr -d '(%)')
fi

10
home/.bin/vol Executable file
View file

@ -0,0 +1,10 @@
#!/usr/bin/env zsh
if [ "$1" = "--up" ]; then
# eww -c $HOME/.dotfiles/eww/bar o vol && wpctl set-volume u/DEFAULT_AUDIO_SINK@ 5%+ && sleep 3 && eww -c $HOME/.dotfiles/eww/bar c vol
swayosd-client --output-volume raise
# wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+
elif [ "$1" = "--down" ]; then
# eww -c $HOME/.dotfiles/eww/bar o vol && wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%- && sleep 3 && eww -c $HOME/.dotfiles/eww/bar c vol
swayosd-client --output-volume lower
# wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-
fi