From ada4b856f61af3d9c5c391dacfedfb155efbac35 Mon Sep 17 00:00:00 2001 From: clsty Date: Wed, 8 Apr 2026 14:01:22 +0800 Subject: [PATCH] Override hyprland entry by default (#3201) and provide --skip-hyprland-entry to skip that --- sdata/subcmd-install/3.files-legacy.sh | 8 +++++++- sdata/subcmd-install/options.sh | 4 +++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/sdata/subcmd-install/3.files-legacy.sh b/sdata/subcmd-install/3.files-legacy.sh index 0a3bef85f..0cdd5fa92 100644 --- a/sdata/subcmd-install/3.files-legacy.sh +++ b/sdata/subcmd-install/3.files-legacy.sh @@ -48,9 +48,15 @@ case "${SKIP_HYPRLAND}" in true) sleep 0;; *) install_dir__sync dots/.config/hypr/hyprland "$XDG_CONFIG_HOME"/hypr/hyprland - for i in hypr{land,lock}.conf {monitors,workspaces}.conf ; do + for i in hyprlock.conf {monitors,workspaces}.conf ; do install_file__auto_backup "dots/.config/hypr/$i" "${XDG_CONFIG_HOME}/hypr/$i" done + for i in hyprland.conf ; do + case "${SKIP_HYPRLAND_ENTRY}" in + true) sleep 0;; + *) install_file "dots/.config/hypr/$i" "${XDG_CONFIG_HOME}/hypr/$i" ;; + esac + done for i in hypridle.conf ; do if [[ "${INSTALL_VIA_NIX}" == true ]]; then install_file__auto_backup "dots-extra/via-nix/$i" "${XDG_CONFIG_HOME}/hypr/$i" diff --git a/sdata/subcmd-install/options.sh b/sdata/subcmd-install/options.sh index 727a3c13b..da2a1e9ba 100644 --- a/sdata/subcmd-install/options.sh +++ b/sdata/subcmd-install/options.sh @@ -20,6 +20,7 @@ Options for install: --skip-backup Skip backup conflicting files --skip-quickshell Skip installing the config for Quickshell --skip-hyprland Skip installing the config for Hyprland + --skip-hyprland-entry Skip installing the entry config for Hyprland --skip-fish Skip installing the config for Fish --skip-fontconfig Skip installing the config for fontconfig --skip-miscconf Skip copying the dirs and files to \".configs\" except for @@ -46,7 +47,7 @@ cleancache(){ # `man getopt` to see more para=$(getopt \ -o hfFk:cs \ - -l help,force,firstrun,fontset:,clean,skip-allgreeting,skip-alldeps,skip-allsetups,skip-allfiles,ignore-outdate,skip-sysupdate,skip-plasmaintg,skip-backup,skip-quickshell,skip-fish,skip-hyprland,skip-fontconfig,skip-miscconf,core,exp-files,via-nix \ + -l help,force,firstrun,fontset:,clean,skip-allgreeting,skip-alldeps,skip-allsetups,skip-allfiles,ignore-outdate,skip-sysupdate,skip-plasmaintg,skip-backup,skip-quickshell,skip-fish,skip-hyprland,skip-hyprland-entry,skip-fontconfig,skip-miscconf,core,exp-files,via-nix \ -n "$0" -- "$@") [ $? != 0 ] && echo "$0: Error when getopt, please recheck parameters." && exit 1 ##################################################################################### @@ -81,6 +82,7 @@ while true ; do --skip-plasmaintg) SKIP_PLASMAINTG=true;shift;; --skip-backup) SKIP_BACKUP=true;shift;; --skip-hyprland) SKIP_HYPRLAND=true;shift;; + --skip-hyprland-entry) SKIP_HYPRLAND_ENTRY=true;shift;; --skip-fish) SKIP_FISH=true;shift;; --skip-quickshell) SKIP_QUICKSHELL=true;shift;; --skip-fontconfig) SKIP_FONTCONFIG=true;shift;;