aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xfiles/imv-folder5
1 files changed, 3 insertions, 2 deletions
diff --git a/files/imv-folder b/files/imv-folder
index 151fc51..33ea051 100755
--- a/files/imv-folder
+++ b/files/imv-folder
@@ -1,7 +1,8 @@
#!/bin/bash
image="$1"
-declare -a ARGS
-for a in "$(dirname "$image")"/*; do
+declare -a ARGS order
+readarray -t -d '' order < <(printf '%s\0' "$(dirname "$image")"/* | sort -z --sort=version)
+for a in "${order[@]}"; do
if [ -f "$a" ]; then
ARGS+=("$a")
fi