diff --git a/.install/hyprland-packages.sh b/.install/hyprland-packages.sh index fbba1da..f216d30 100644 --- a/.install/hyprland-packages.sh +++ b/.install/hyprland-packages.sh @@ -1,5 +1,4 @@ packagesPacman=( - "hyprland" "xdg-desktop-portal-hyprland" "waybar" "grim" diff --git a/.install/hyprland-version.sh b/.install/hyprland-version.sh new file mode 100644 index 0000000..02a3c72 --- /dev/null +++ b/.install/hyprland-version.sh @@ -0,0 +1,61 @@ +# ------------------------------------------------------ +# Select installation profile +# ------------------------------------------------------ +echo -e "${GREEN}" +figlet "Hyprland" +echo -e "${NONE}" + +hyprland_installed=0 +hyprlandgit_installed=0 +hyprland_package="" +echo "Hyprland is available in two differnet versions: " +echo "hyprland with the lastest official release " +echo "hyprland-git compiled from latest source." +echo +echo "Check for installed hyprland package..." +if [[ $(_isInstalledYay "hyprland-git") == 0 ]]; then + echo "hyprland-git already installed!" + hyprlandgit_installed=1 +elif [[ $(_isInstalledPacman "hyprland") == 0 ]]; then + echo "hyprland already installed!" + hyprland_installed=1 +else + echo "hyprland NOT installed!" +fi +echo +if [ $hyprland_installed == "1" ] ;then + echo "Hyprland is already installed with the package hyprland on your system. How do you want to proceed?" + echo "RETURN = confirm. ESC = Keep hyprland" + hyprsel=$(gum choose "KEEP hyprland" "Replace with hyprland-git") + if [ "$hyprsel" == "Replace with hyprland-git" ] ;then + echo "Replace hyprland with hyprland-git." + yay --noconfirm -R hyprland + _forcePackagesYay "hyprland-git"; + else + echo "Keep current hyprland installation." + fi +elif [ $hyprlandgit_installed == "1" ] ;then + echo "Hyprland is already installed with the package hyprland-git on your system. How do you want to proceed?" + echo "RETURN = confirm. ESC = Keep hyprland-git" + hyprsel=$(gum choose "KEEP hyprland-git" "Replace with hyprland") + if [ "$hyprsel" == "Replace with hyprland" ] ;then + echo "Replace hyprland-git with hyprland." + yay --noconfirm -R hyprland-git + _forcePackagesYay "hyprland"; + else + echo "Keep current hyprland installation." + fi +else + # No hyprland found on the system + echo "RETURN = confirm. No selection = CANCEL" + hypr_version=$(gum choose "hyprland" "hyprland-git") + if [ -z $hypr_version ] ;then + echo "No profile selected. Installation canceled." + exit + fi + if [ "$hypr_version" == "hyprland" ] ;then + _installPackagesYay "hyprland"; + else + _installPackagesYay "hyprland-git"; + fi +fi diff --git a/.install/profile.sh b/.install/profile.sh index 91fcfb0..fd6db0d 100755 --- a/.install/profile.sh +++ b/.install/profile.sh @@ -2,7 +2,7 @@ # Select installation profile # ------------------------------------------------------ echo -e "${GREEN}" -figlet "Desktop Profile" +figlet "Profile" echo -e "${NONE}" echo "SPACE = select/unselect a profile. RETURN = confirm. No selection = CANCEL" @@ -10,4 +10,6 @@ profile=$(gum choose --no-limit --cursor-prefix "( ) " --selected-prefix "(x) " if [ -z $profile ] ;then echo "No profile selected. Installation canceled." exit +else + echo "Profile/s selected: $profile" fi diff --git a/CHANGELOG b/CHANGELOG index d5ec6cb..b2cb80e 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -4,10 +4,12 @@ https://gitlab.com/stephan-raabe/dotfiles/-/releases/2.7 Installation: - Display Manager SDDM and sugar-candy theme will be installed. - Optional display manager disablement possible -- Arco Linux is now supported. Please reinstall/force the installation of all packages during the installation/update script. +- Select between hyprland or hyprland-git +- Arco Linux is now supported. Please choose hyprland-git and reinstall/force the installation of all packages during the installation/update script. General: - Adding icons to eza. Adding ls, ll, lt +- New alacritty.toml configuration file Hyprland: - New Waybar Module Idle Inhibitor to deactivate the automatic start of swaylock e.g. to watch videos or for online meetings diff --git a/install.sh b/install.sh index b2ebd9c..2e8ef9c 100755 --- a/install.sh +++ b/install.sh @@ -35,15 +35,17 @@ fi echo "" source .install/required.sh source .install/confirm-start.sh +source .install/yay.sh source .install/backup.sh source .install/preparation.sh source .install/profile.sh -source .install/yay.sh +if [[ $profile == *"Hyprland"* ]]; then + source .install/hyprland-version.sh +fi source .install/installer.sh source .install/general.sh source .install/general-packages.sh source .install/install-packages.sh - if [[ $profile == *"Hyprland"* ]]; then source .install/hyprland.sh source .install/hyprland-packages.sh diff --git a/qtile/config.py b/qtile/config.py index 5a851d5..1d00b4f 100644 --- a/qtile/config.py +++ b/qtile/config.py @@ -300,7 +300,7 @@ widget_list = [ text=" ", foreground="000000.6", fontsize=18, - mouse_callbacks={"Button1": lambda: qtile.cmd_spawn(home + "/dotfiles/.settings/browser.sh")}, + mouse_callbacks={"Button1": lambda: qtile.cmd_spawn("bash " + home + "/dotfiles/.settings/browser.sh")}, ), widget.TextBox( **decor_left, @@ -308,7 +308,7 @@ widget_list = [ text=" ", foreground="000000.6", fontsize=18, - mouse_callbacks={"Button1": lambda: qtile.cmd_spawn(home + "/dotfiles/.settings/filemanager.sh")} + mouse_callbacks={"Button1": lambda: qtile.cmd_spawn("bash " + home + "/dotfiles/.settings/filemanager.sh")} ), widget.WindowName(