This got... long... and complicated. But I think it's a really good demonstration of getting redo to do complicated things elegantly. At least, I hope it is.
9 lines
145 B
Bash
Executable file
9 lines
145 B
Bash
Executable file
#!/bin/sh
|
|
fail=0
|
|
for d in "$@"; do
|
|
if ! type "$d" >/dev/null 2>/dev/null; then
|
|
echo " -- missing tool: $d" >&2
|
|
fail=1
|
|
fi
|
|
done
|
|
exit "$fail"
|