From 2088bdc2b5ef8c2823e6f2e4997871818417672e Mon Sep 17 00:00:00 2001 From: Don Williams Date: Thu, 22 Jan 2026 19:23:58 -0500 Subject: fix: UserConfigs dedupe handling for express/update --- scripts/lib_copy.sh | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'scripts') diff --git a/scripts/lib_copy.sh b/scripts/lib_copy.sh index ace6f4d7..331c6906 100644 --- a/scripts/lib_copy.sh +++ b/scripts/lib_copy.sh @@ -427,9 +427,14 @@ restore_user_configs() { fi # Always run de-dupe based on the installed dotfiles version so that - # express mode and standard mode behave consistently. - local detected_version - detected_version=$(get_installed_dotfiles_version) + # express mode and standard mode behave consistently. Prefer the + # pre-upgrade version (old_version) if provided so we still clean up + # legacy duplicates when upgrading to a newer release that no longer + # needs the fix. + local detected_version="$old_version" + if [ -z "$detected_version" ]; then + detected_version=$(get_installed_dotfiles_version) + fi if [ -n "$detected_version" ]; then cleanup_duplicate_userconfigs "$detected_version" "$log" fi -- cgit v1.2.3