Pick the test ISO like omarchy-iso-boot does
Offer the same gum chooser over release/*.iso when no ISO is passed, and fail plainly when there is no existing ISO to test. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
1 parent
a72a109e7a
commit
01a5203009
1 file changed
+3
-2
@@ -61,11 +61,12 @@ while (($#)); do
|
|||||||
shift
|
shift
|
||||||
done
|
done
|
||||||
|
|
||||||
if [[ -z $ISO ]]; then
|
if [[ -z $ISO && -t 0 ]]; then
|
||||||
ISO=$(ls -t "$REPO_DIR"/release/*.iso 2>/dev/null | head -1) || true
|
ISO=$(ls -t "$REPO_DIR"/release/*.iso 2>/dev/null | gum choose --header "Select ISO to test")
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ ! -f ${ISO:-} ]]; then
|
if [[ ! -f ${ISO:-} ]]; then
|
||||||
|
echo "No ISO to test. Pass one explicitly or put it in release/." >&2
|
||||||
echo "Usage: omarchy-iso-test [release/omarchy.iso] [options]" >&2
|
echo "Usage: omarchy-iso-test [release/omarchy.iso] [options]" >&2
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in new issue
Block a user