From a065ed1fcfcffd9eddbd3c4c848da1f6c6ae9dd0 Mon Sep 17 00:00:00 2001 From: JaKooLit Date: Sat, 19 Jul 2025 20:24:26 +0900 Subject: Fixed the uncommenting part of UserKeybinds.conf --- copy.sh | 23 +++++++++-------------- 1 file changed, 9 insertions(+), 14 deletions(-) diff --git a/copy.sh b/copy.sh index e2c06bc1..3677c86e 100755 --- a/copy.sh +++ b/copy.sh @@ -241,31 +241,26 @@ if command -v ags >/dev/null 2>&1; then sed -i '/#ags -q && ags &/s/^#//' config/hypr/scripts/RefreshNoWaybar.sh sed -i '/#ags -q && ags &/s/^#//' config/hypr/scripts/Refresh.sh - # Uncomment the ags overview keybind (tolerates spaces/tabs) - sed -i '/^\s*#\s*bind\s*=\s*\$mainMod,\s*A,\s*exec,\s*pkill rofi\s*\|\|\s*true\s*&&\s*ags\s*-t\s*'\''overview'\''/s/^\s*#\s*//' config/hypr/UserConfigs/UserKeybinds.conf + # Uncomment the ags overview keybind + sed -i '/^#bind = \$mainMod, A, exec, pkill rofi || true && ags -t '\''overview'\''/s/^#//' config/hypr/UserConfigs/UserKeybinds.conf - # Comment the quickshell line if not already commented (tolerates spaces/tabs) - sed -i '/^\s*bind\s*=\s*\$mainMod,\s*A,\s*global,\s*quickshell:overviewToggle/{ - s/^\s*/#/ - }' config/hypr/UserConfigs/UserKeybinds.conf + # Comment the quickshell line if not already commented + sed -i '/^\s*bind\s*=\s*\$mainMod,\s*A,\s*global,\s*quickshell:overviewToggle/{s/^\s*/#/}' config/hypr/UserConfigs/UserKeybinds.conf fi -# Check if quickshell is installed edit quickshell behaviour on configs +# Check if quickshell is installed; edit quickshell behaviour on configs if command -v qs >/dev/null 2>&1; then sed -i '/^\s*#exec-once = qs/s/^#//' config/hypr/UserConfigs/Startup_Apps.conf sed -i '/#pkill qs && qs &/s/^#//' config/hypr/scripts/RefreshNoWaybar.sh sed -i '/#pkill qs && qs &/s/^#//' config/hypr/scripts/Refresh.sh - # Uncomment the quickshell keybind line (tolerates spaces/tabs) - sed -i '/^\s*#\s*bind\s*=\s*\$mainMod,\s*A,\s*global,\s*quickshell:overviewToggle/s/^\s*#\s*//' config/hypr/UserConfigs/UserKeybinds.conf + # Uncomment the quickshell keybind line + sed -i "/^#bind = \$mainMod, A, global, quickshell:overviewToggle/s/^#//" config/hypr/UserConfigs/UserKeybinds.conf - # Ensure the ags overview keybind is commented (tolerates spaces/tabs) - sed -i '/^\s*bind\s*=\s*\$mainMod,\s*A,\s*exec,\s*pkill rofi\s*\|\|\s*true\s*&&\s*ags\s*-t\s*'\''overview'\''/{ - s/^\s*/#/ - }' config/hypr/UserConfigs/UserKeybinds.conf + # Ensure the ags overview keybind is commented + sed -i "/^\s*bind\s*=\s*\\\$mainMod,\s*A,\s*exec,\s*pkill rofi\s*||\s*true\s*&&\s*ags\s*-t\s*'overview'/{s/^\s*/#/}" config/hypr/UserConfigs/UserKeybinds.conf fi - printf "\n%.0s" {1..1} # Checking if neovim or vim is installed and offer user if they want to make as default editor -- cgit v1.2.3