23 lines
482 B
Bash
Executable File
23 lines
482 B
Bash
Executable File
#!/usr/bin/env zsh
|
|
# Run commonly-used SubX programs using the SubX VM in 'debug mode'.
|
|
|
|
if [ $# -eq 0 ]
|
|
then
|
|
echo "Usage: $0 <binary name without directory> <args>"
|
|
echo
|
|
echo "Naming convention: Binaries starting with 'ex' will be assumed to live in examples/"
|
|
echo "Other binaries will be assumed to live in apps/"
|
|
exit 1
|
|
fi
|
|
|
|
case $1 in
|
|
ex*)
|
|
./subx --map --trace run examples/$*
|
|
exit $?
|
|
;;
|
|
*)
|
|
./subx --map --trace run apps/$*
|
|
exit $?
|
|
;;
|
|
esac
|