mirror of
https://github.com/lordmathis/dotfiles.git
synced 2025-11-06 01:34:22 +00:00
Housekeeping
This commit is contained in:
@@ -25,7 +25,12 @@ get_icon() {
|
||||
}
|
||||
|
||||
KEY=`secret-tool lookup openweathermap api_key`
|
||||
CITY=""
|
||||
|
||||
BRNO_CZ="3078610"
|
||||
ZVOLEN_SK="3056459"
|
||||
|
||||
CITY=$BRNO_CZ
|
||||
|
||||
UNITS="metric"
|
||||
SYMBOL="°"
|
||||
|
||||
@@ -15,14 +15,8 @@ volume_mute() {
|
||||
}
|
||||
|
||||
volume_print() {
|
||||
if pacmd list-sinks | grep active | head -n 1 | grep -q speaker; then
|
||||
icon=""
|
||||
elif pacmd list-sinks | grep active | head -n 1 | grep headphones; then
|
||||
icon=""
|
||||
else
|
||||
icon=""
|
||||
fi
|
||||
|
||||
|
||||
icon=""
|
||||
muted=$(pamixer --sink $sink --get-mute)
|
||||
|
||||
if [ "$muted" = true ]; then
|
||||
7
bin/polybar/vpn_running.sh
Executable file
7
bin/polybar/vpn_running.sh
Executable file
@@ -0,0 +1,7 @@
|
||||
#!/bin/sh
|
||||
|
||||
if [ "$(pgrep openvpn)" ]; then
|
||||
echo ""
|
||||
else
|
||||
echo
|
||||
fi
|
||||
@@ -1,9 +0,0 @@
|
||||
#!/bin/bash
|
||||
intern=eDP-1
|
||||
extern=HDMI-1
|
||||
|
||||
if xrandr --listactivemonitors | grep "$intern"; then
|
||||
xrandr --output "$intern" --off
|
||||
else
|
||||
xrandr --output "$intern" --auto
|
||||
fi
|
||||
21
bin/xrandr/switch_monitors.sh
Executable file
21
bin/xrandr/switch_monitors.sh
Executable file
@@ -0,0 +1,21 @@
|
||||
#!/bin/bash
|
||||
|
||||
intern=eDP-1
|
||||
extern=HDMI-1
|
||||
|
||||
case $1 in
|
||||
"-i")
|
||||
m=$intern
|
||||
;;
|
||||
"-e")
|
||||
m=$extern
|
||||
;;
|
||||
*)
|
||||
echo "Wrong option"
|
||||
esac
|
||||
|
||||
if xrandr --listactivemonitors | grep "$m"; then
|
||||
xrandr --output "$m" --off
|
||||
else
|
||||
xrandr --output "$m" --auto
|
||||
fi
|
||||
Reference in New Issue
Block a user