diff --git a/.config/Scripts/bluetoothctl.sh b/.config/Scripts/bluetoothctl.sh deleted file mode 100755 index 6d66e6c..0000000 --- a/.config/Scripts/bluetoothctl.sh +++ /dev/null @@ -1,60 +0,0 @@ -#!/bin/sh - -bluetooth_print() { - bluetoothctl | while read -r; do - if [ "$(systemctl is-active "bluetooth.service")" = "active" ]; then - printf '#1' - - devices_paired=$(bluetoothctl paired-devices | grep Device | cut -d ' ' -f 2) - counter=0 - - echo "$devices_paired" | while read -r line; do - device_info=$(bluetoothctl info "$line") - - if echo "$device_info" | grep -q "Connected: yes"; then - device_alias=$(echo "$device_info" | grep "Alias" | cut -d ' ' -f 2-) - - if [ $counter -gt 0 ]; then - printf ", %s" "$device_alias" - else - printf " %s" "$device_alias" - fi - - counter=$((counter + 1)) - fi - - printf '\n' - done - else - echo "#2" - fi - done -} - -bluetooth_toggle() { - if bluetoothctl show | grep -q "Powered: no"; then - bluetoothctl power on >> /dev/null - sleep 1 - - devices_paired=$(bluetoothctl paired-devices | grep Device | cut -d ' ' -f 2) - echo "$devices_paired" | while read -r line; do - bluetoothctl connect "$line" >> /dev/null - done - else - devices_paired=$(bluetoothctl paired-devices | grep Device | cut -d ' ' -f 2) - echo "$devices_paired" | while read -r line; do - bluetoothctl disconnect "$line" >> /dev/null - done - - bluetoothctl power off >> /dev/null - fi -} - -case "$1" in - --toggle) - bluetooth_toggle - ;; - *) - bluetooth_print - ;; -esac diff --git a/.config/Scripts/expressvpn-status.sh b/.config/Scripts/expressvpn-status.sh deleted file mode 100755 index d412c9b..0000000 --- a/.config/Scripts/expressvpn-status.sh +++ /dev/null @@ -1,19 +0,0 @@ - -#!/bin/sh - -STATUS=$(expressvpn status | cut -d " " -f 1) -IP=$(ip route get 8.8.8.8 | head -1 | awk '{print $7}') -SSID=$(nmcli -f SSID | head -1 | cut -d " " -f 4) - -if [ "$STATUS" != "Not" ]; then - echo " ${IP} " - -elif [ "$SSID" = "ASUS_5G" ] || [ "$SSID" = "ASUS" ]; then - echo " ${IP} " - -elif [ "$SSID" = "OP3T" ] || [ "$SSID" = "Samsung" ]; then - echo " ${IP} " - -elif [ "$SSID" != "ASUS_5G" ] || [ "$SSID" != "ASUS" ] || [ "$SSID" != "OP3T" ] || [ "$SSID" != "Samsung" ] ; then - echo " ${IP} " -fi diff --git a/.config/polybar/config b/.config/polybar/config index 0902f8e..4b20ae8 100644 --- a/.config/polybar/config +++ b/.config/polybar/config @@ -118,16 +118,16 @@ content-background = #00000000 [module/bluetoothctl] type = custom/script -exec = ~/.config/Scripts/bluetoothctl.sh +exec = ~/.config/polybar/scripts/bluetoothctl.sh tail = true -click-left = ~/.config/Scripts/bluetoothctl.sh --toggle +click-left = ~/.config/polybar/scripts/bluetoothctl.sh --toggle label = " %output% " label-foreground = ${colors.color0} label-background = ${colors.color6} [module/expressvpn-status] type = custom/script -exec = ~/.config/Scripts/expressvpn-status.sh +exec = ~/.config/polybar/scripts/expressvpn-status.sh interval = 5 ;format-foreground = #E5E9F0 ;format-backgound = #5E81AC @@ -139,11 +139,11 @@ label-background = ${colors.color3} type = custom/script tail = true label = " %output% " -exec = ~/.config/Scripts/pavolume.sh --listen +exec = ~/.config/polybar/scripts/pavolume.sh --listen click-right = exec pavucontrol -click-left = ~/.config/Scripts/pavolume.sh --togmute -scroll-up = ~/.config/Scripts/pavolume.sh --up -scroll-down = ~/.config/Scripts/pavolume.sh --down +click-left = ~/.config/polybar/scripts/pavolume.sh --togmute +scroll-up = ~/.config/polybar/scripts/pavolume.sh --up +scroll-down = ~/.config/polybar/scripts/pavolume.sh --down format-foreground = ${colors.color0} format-background = ${colors.color6} @@ -164,10 +164,10 @@ label-unmounted-foreground = ${colors.foreground-alt} [module/redshift] type = custom/script format-prefix = " " -exec = source ~/.config/Scripts/redshift/env.sh && ~/.config/Scripts/redshift/redshift.sh temperature -click-left = source ~/.config/Scripts/redshift/env.sh && ~/.config/Scripts/redshift/redshift.sh toggle -scroll-up = source ~/.config/Scripts/redshift/env.sh && ~/.config/Scripts/redshift/redshift.sh increase -scroll-down = source ~/.config/Scripts/redshift/env.sh && ~/.config/Scripts/redshift/redshift.sh decrease +exec = source ~/.config/polybar/scripts/redshift/env.sh && ~/.config/polybar/scripts/redshift/redshift.sh temperature +click-left = source ~/.config/polybar/scripts/redshift/env.sh && ~/.config/polybar/scripts/redshift/redshift.sh toggle +scroll-up = source ~/.config/polybar/scripts/redshift/env.sh && ~/.config/polybar/scripts/redshift/redshift.sh increase +scroll-down = source ~/.config/polybar/scripts/redshift/env.sh && ~/.config/polybar/scripts/redshift/redshift.sh decrease interval=0.5 format-foreground = ${colors.color0} format-background = ${colors.color6} @@ -175,7 +175,7 @@ format-background = ${colors.color6} [module/backlight] type = custom/script interval = 0.2 -exec = ~/.config/Scripts/backlight.sh +exec = ~/.config/polybar/scripts/backlight.sh scroll-up = exec light -A 5 scroll-down = exec light -U 5 format-prefix = "  " @@ -187,9 +187,9 @@ label-background = ${colors.color3} [module/popup-calendar] type = custom/script -exec = ~/.config/Scripts/popup-calendar.sh +exec = ~/.config/polybar/scripts/popup-calendar.sh interval = 5 -click-left = ~/.config/Scripts/popup-calendar.sh --popup +click-left = ~/.config/polybar/scripts/popup-calendar.sh --popup format-prefix = "  " format-prefix-foreground = ${colors.color0} format-prefix-background = ${colors.color15} @@ -242,7 +242,7 @@ ramp-foreground = ${colors.foreground} [module/pkg] type = custom/script -exec = "~/.config/Scripts/arch-updates.sh -s" +exec = "~/.config/polybar/scripts/arch/arch-updates.sh -s" tail = true format = "