apply DRY and enhance progress in update.sh
All checks were successful
CI Pipeline / shasums (push) Successful in 6s
git-sync-with-mirror / git-sync (push) Successful in 9s
CI Pipeline / build (push) Successful in 44s
CI Pipeline / tests (push) Successful in 30s
CI Pipeline / performance (push) Successful in 9s

- Centralize constants and remove code duplication
- Implement dynamic progress bar with real file count
- Remove artificial delays for improved performance
This commit is contained in:
2025-11-05 21:56:20 -05:00
parent ece6e2f1d4
commit a97b72bd62
2 changed files with 2 additions and 2 deletions

View File

@@ -144,7 +144,7 @@ function updbashrc() {
local full_path="$HYPERTERM_DIR/$file_path" local full_path="$HYPERTERM_DIR/$file_path"
# Check if file exists and has correct hash # Check if file exists and has correct hash
if [[ ! -f "$full_path" ]] || ! echo "$expected_hash ./$file_path" | (cd "$HYPERTERM_DIR" && sha512sum -c --quiet 2>&1 >/dev/null); then if [[ ! -f "$full_path" ]] || ! echo "$expected_hash ./$file_path" | (cd "$HYPERTERM_DIR" && sha512sum -c --quiet >/dev/null 2>&1); then
files_to_update+=("$file_path") files_to_update+=("$file_path")
fi fi
done < "$HYPERTERM_DIR/hyperterm.sha512" done < "$HYPERTERM_DIR/hyperterm.sha512"

View File

@@ -1,6 +1,6 @@
cdfe049ec07f02a1893cda29c13085d06709e09a30b0c2e1111585278315f03139d61080c883cb3fd87f2bf64e05d9b5e5eaaad84c97ced890d83c73eb399fcb ../.bash_profile cdfe049ec07f02a1893cda29c13085d06709e09a30b0c2e1111585278315f03139d61080c883cb3fd87f2bf64e05d9b5e5eaaad84c97ced890d83c73eb399fcb ../.bash_profile
f363606f41a2c2c8f1cc44110c64fe23b1c8feb4c788ee006222db0f5c7a3adeac2b0948626b313adc985e9b8d303a0b9ce1c5ba42746810accb54efddcd4b84 ./hyperterm.sh f363606f41a2c2c8f1cc44110c64fe23b1c8feb4c788ee006222db0f5c7a3adeac2b0948626b313adc985e9b8d303a0b9ce1c5ba42746810accb54efddcd4b84 ./hyperterm.sh
1a1d23ee7078c513049d96cf56c7e8187dcd5191a014b43338e1d9e09642ec6f128b746b564ee2e818da7eace70aa183d2d275e83b4c8195067a35adb595f647 ./core/update.sh 5cd7bb68cbdd969b72a9355471927955696d15ac223d08468528bff103d8525339c16b374edf4d71aeb76e1776bad86727a15bc1bf684adba5d40465ad82894b ./core/update.sh
1cfba599047d84a17ff92b695ebf527a505a30acc9ec21a2b9f410a7ea6dde4b23b5cf62e557d82f2fe9a8980649942424b879ca53baae4d4cb3057681baa7b6 ./core/colors.sh 1cfba599047d84a17ff92b695ebf527a505a30acc9ec21a2b9f410a7ea6dde4b23b5cf62e557d82f2fe9a8980649942424b879ca53baae4d4cb3057681baa7b6 ./core/colors.sh
c5ae12ee08361d1264fde5c73868fd0a80fd8810ac4e614cc333335679ad68d629d9bb88a04d27a8002d62f454105f1168df9ea63c7300c9272380b6d5311278 ./core/git.sh c5ae12ee08361d1264fde5c73868fd0a80fd8810ac4e614cc333335679ad68d629d9bb88a04d27a8002d62f454105f1168df9ea63c7300c9272380b6d5311278 ./core/git.sh
f3e00b2aa8ab9f3ab44570adaa2520408ed66fd00f551654d60b64a4be3546ec781b7efa39bcd774937e654b6ffb4c7af3f21eeb36caf9c01f82f85cf28e2b4d ./core/languages.sh f3e00b2aa8ab9f3ab44570adaa2520408ed66fd00f551654d60b64a4be3546ec781b7efa39bcd774937e654b6ffb4c7af3f21eeb36caf9c01f82f85cf28e2b4d ./core/languages.sh