aboutsummaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2016-09-05 11:29:15 +1200
committerTom Ryder <tom@sanctum.geek.nz>2016-09-05 11:29:15 +1200
commit61c1c0be3c258635ad25dbbe652c4ccf30837324 (patch)
treead7c5af094acf4f2d3df894a719b5ad28e3894a7 /bin
parentClean up all/install-bin targets (diff)
downloaddotfiles-61c1c0be3c258635ad25dbbe652c4ccf30837324.tar.gz
dotfiles-61c1c0be3c258635ad25dbbe652c4ccf30837324.zip
Add umake(1df)
Diffstat (limited to 'bin')
-rwxr-xr-xbin/umake11
1 files changed, 11 insertions, 0 deletions
diff --git a/bin/umake b/bin/umake
new file mode 100755
index 00000000..8c8d4850
--- /dev/null
+++ b/bin/umake
@@ -0,0 +1,11 @@
+#!/bin/sh
+# Keep going up the tree until we find a Makefile, and then run make(1) with
+# any given args
+while [ "$PWD" != / ] ; do
+ if [ -f Makefile ] ; then
+ exec make "$@" || exit
+ fi
+ cd .. || exit
+done
+printf >&2 'umake: No Makefile found in ancestors\n'
+exit 1