diff --git a/scripts/.local/bin/usb-status.sh b/scripts/.local/bin/usb-status.sh deleted file mode 100755 index 7dcdf0b..0000000 --- a/scripts/.local/bin/usb-status.sh +++ /dev/null @@ -1,13 +0,0 @@ -#!/usr/bin/env dash - -if usbctl check; then - TEXT="\uf023" - TOOLTIP="PROTECTED" - CLASS="protected" -else - TEXT="\uf3c1" - TOOLTIP="UNPROTECTED" - CLASS="unprotected" -fi - -env echo "{\"text\": \"${TEXT}\", \"tooltip\": \"${TOOLTIP}\", \"class\": \"${CLASS}\"}" diff --git a/scripts/.local/bin/usb-unlock.sh b/scripts/.local/bin/usb-unlock.sh deleted file mode 100755 index eb392d4..0000000 --- a/scripts/.local/bin/usb-unlock.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/usr/bin/env dash - -if usbctl check; then - MODE="$([ "$1" = "--permanent" ] && printf "unprotect" || printf "temporary")" - pkexec --disable-internal-agent usbctl "$MODE" -else - pkexec --disable-internal-agent usbctl protect -fi diff --git a/sway/.config/sway/config.d/01_keybinds b/sway/.config/sway/config.d/01_keybinds index adbe946..f7b73ae 100644 --- a/sway/.config/sway/config.d/01_keybinds +++ b/sway/.config/sway/config.d/01_keybinds @@ -23,9 +23,6 @@ bindsym $mod+Shift+c reload # Lock the screen bindsym $mod+l exec swaylock -# Unlock USB protection -bindsym $mod+u exec usb-unlock.sh - # Session and power management bindsym $mod+Shift+e exec swaynag -t logout -m 'Log out?' -b 'Yes' 'swaymsg exit' bindsym $mod+Shift+r exec swaynag -t reboot -m 'Reboot?' -b 'Yes' 'doas reboot' diff --git a/waybar/.config/waybar/config b/waybar/.config/waybar/config index ee44048..6bf103e 100644 --- a/waybar/.config/waybar/config +++ b/waybar/.config/waybar/config @@ -3,7 +3,7 @@ "layer": "top", "position": "top", "height": 36, - "modules-left": ["idle_inhibitor", "sway/workspaces", "custom/usb", "sway/mode"], + "modules-left": ["idle_inhibitor", "sway/workspaces", "sway/mode"], "modules-center": ["clock"], "modules-right": ["network", "pulseaudio", "backlight", "cpu", "memory", "battery", "tray"], "sway/workspaces": { @@ -80,13 +80,5 @@ "backlight": { "format": "{icon} {percent}%", "format-icons": ["", "", "", "", "", "", "", "", ""] - }, - "custom/usb": { - "format": "{} USB", - "exec": "usb-status.sh", - "return-type": "json", - "interval": 1, - "on-click": "usb-unlock.sh", - "on-click-right": "usb-unlock.sh --permanent" } } diff --git a/waybar/.config/waybar/style.css b/waybar/.config/waybar/style.css index 590eb2d..6d8a084 100644 --- a/waybar/.config/waybar/style.css +++ b/waybar/.config/waybar/style.css @@ -88,8 +88,7 @@ window#waybar.hidden { #tray, #mode, #idle_inhibitor, -#mpd, -#custom-usb { +#mpd { padding: 0 4px; margin: 0 4px; color: @white; @@ -198,13 +197,3 @@ label:focus { color: @violet; box-shadow: inset 0 3px @violet; } - -#custom-usb { - color: @orange; - box-shadow: inset 0 3px @orange; -} - -#custom-usb.unprotected { - color: @red; - box-shadow: inset 0 3px @red; -} diff --git a/zsh/.config/zsh/aliases.zsh b/zsh/.config/zsh/aliases.zsh index 37bc312..02b3393 100644 --- a/zsh/.config/zsh/aliases.zsh +++ b/zsh/.config/zsh/aliases.zsh @@ -67,7 +67,6 @@ if [[ $(lsb_release -si) == "Artix" ]]; then alias pacss="pacman -Ss" alias poweroff="doas poweroff" alias reboot="doas reboot" - alias usb="doas usbctl tmp" elif [[ $(lsb_release -si) == "Fedora" ]]; then alias code="codium" alias dnfin="sudo dnf install"