stargazing/notwa-util/expand

12 lines
306 B
Bash
Executable File

#!/usr/bin/env sh
o=o/"$mode" once=false
for f; do g="${f#?//}"; case "$f" in
(a//*) f="$o/ape/$g";;
(b//*) f="$o/tool/build/$g";;
(e//*) f="$o/examples/$g";;
(o//*) f="$o/$g";;
(t//*) f="$o/third_party/$g";;
(T//*) f="third_party/$g";;
esac; $once && set -- "$@" "$f" || set -- "$f"; once=true; done
"$@"