V8.00.000.2025.06.17
All checks were successful
🛡️ Shell Script Linting / 🛡️ Shell Script Linting (push) Successful in 1m52s

Signed-off-by: Marc S. Weidner <msw@coresecret.dev>
This commit is contained in:
2025-08-28 23:21:59 +02:00
parent 60e38420e5
commit 70184c3323
2 changed files with 20 additions and 4 deletions

View File

@@ -343,7 +343,20 @@ partitioning() {
### Prepare mount ordering scheme.
# shellcheck disable=SC2312
IFS=$'\n' read -r -d '' -a ARY_PATHS_SORTED < <(printf "%s\n" "${ary_paths_unsorted[@]}" | sort -u | awk 'BEGIN{FS="/"}{print NF, $0}' | sort -n | cut -d' ' -f2- && printf '\0')
IFS=$'\n' read -r -d '' -a ARY_PATHS_SORTED < <(
printf "%s\n" "${ary_paths_unsorted[@]}" \
| sort -u \
| awk '
BEGIN{root_seen=0}
$0=="/"{root_seen=1; print; next}
$0=="SWAP"{swap=1; next}
/^\//{print; next}
{print} # any other tokens if ever used
END{ if (swap) print "SWAP" }
' \
&& printf "\0"
)
#IFS=$'\n' read -r -d '' -a ARY_PATHS_SORTED < <(printf "%s\n" "${ary_paths_unsorted[@]}" | sort -u | awk 'BEGIN{FS="/"}{print NF, $0}' | sort -n | cut -d' ' -f2- && printf '\0')
printf "%s\n" "${ary_paths_unsorted[@]}" >| "${DIR_LOG}/mount_paths_unsorted.log"
printf "%s\n" "${ARY_PATHS_SORTED[@]}" >| "${DIR_LOG}/mount_paths_sorted.log"