forked from Shinonome/dots-hyprland
Improve handle deprecated deps logic (#2425)
This commit is contained in:
@@ -14,9 +14,11 @@ install-yay(){
|
|||||||
|
|
||||||
# NOTE: `handle-deprecated-dependencies` was for the old days when we just switch from dependencies.conf to local PKGBUILDs.
|
# NOTE: `handle-deprecated-dependencies` was for the old days when we just switch from dependencies.conf to local PKGBUILDs.
|
||||||
# However, let's just keep it as references for other distros writing their `sdata/dist-<DISTRO_ID>/install-deps.sh`, if they need it.
|
# However, let's just keep it as references for other distros writing their `sdata/dist-<DISTRO_ID>/install-deps.sh`, if they need it.
|
||||||
handle-deprecated-dependencies(){
|
remove_deprecated_dependencies(){
|
||||||
printf "${STY_CYAN}[$0]: Removing deprecated dependencies:${STY_RST}\n"
|
printf "${STY_CYAN}[$0]: Removing deprecated dependencies:${STY_RST}\n"
|
||||||
for i in illogical-impulse-{microtex,pymyc-aur} hyprland-qtutils {quickshell,hyprutils,hyprpicker,hyprlang,hypridle,hyprland-qt-support,hyprland-qtutils,hyprlock,xdg-desktop-portal-hyprland,hyprcursor,hyprwayland-scanner,hyprland}-git;do try sudo pacman --noconfirm -Rdd $i;done
|
for i in illogical-impulse-{microtex,pymyc-aur} hyprland-qtutils {quickshell,hyprutils,hyprpicker,hyprlang,hypridle,hyprland-qt-support,hyprland-qtutils,hyprlock,xdg-desktop-portal-hyprland,hyprcursor,hyprwayland-scanner,hyprland}-git;do try sudo pacman --noconfirm -Rdd $i;done
|
||||||
|
}
|
||||||
|
implicitize_old_dependencies(){
|
||||||
# Convert old dependencies to non explicit dependencies so that they can be orphaned if not in meta packages
|
# Convert old dependencies to non explicit dependencies so that they can be orphaned if not in meta packages
|
||||||
remove_bashcomments_emptylines ./sdata/dist-arch/previous_dependencies.conf ./cache/old_deps_stripped.conf
|
remove_bashcomments_emptylines ./sdata/dist-arch/previous_dependencies.conf ./cache/old_deps_stripped.conf
|
||||||
readarray -t old_deps_list < ./cache/old_deps_stripped.conf
|
readarray -t old_deps_list < ./cache/old_deps_stripped.conf
|
||||||
@@ -37,6 +39,9 @@ if ! command -v pacman >/dev/null 2>&1; then
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
showfun remove_deprecated_dependencies
|
||||||
|
v remove_deprecated_dependencies
|
||||||
|
|
||||||
# Issue #363
|
# Issue #363
|
||||||
case $SKIP_SYSUPDATE in
|
case $SKIP_SYSUPDATE in
|
||||||
true) sleep 0;;
|
true) sleep 0;;
|
||||||
@@ -51,8 +56,8 @@ if ! command -v yay >/dev/null 2>&1;then
|
|||||||
v install-yay
|
v install-yay
|
||||||
fi
|
fi
|
||||||
|
|
||||||
showfun handle-deprecated-dependencies
|
showfun implicitize_old_dependencies
|
||||||
v handle-deprecated-dependencies
|
v implicitize_old_dependencies
|
||||||
|
|
||||||
# https://github.com/end-4/dots-hyprland/issues/581
|
# https://github.com/end-4/dots-hyprland/issues/581
|
||||||
# yay -Bi is kinda hit or miss, instead cd into the relevant directory and manually source and install deps
|
# yay -Bi is kinda hit or miss, instead cd into the relevant directory and manually source and install deps
|
||||||
|
|||||||
Reference in New Issue
Block a user