aboutsummaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2016-12-07 11:18:35 +1300
committerTom Ryder <tom@sanctum.geek.nz>2016-12-07 11:18:35 +1300
commitfad17a0bdacc93a2f0ec4097ee5f4b0a033eee0e (patch)
tree1b161c9e96eaea85e837adf5a9b1ad8943e14aa3 /bin
parentAdd loc(1df) (diff)
downloaddotfiles-fad17a0bdacc93a2f0ec4097ee5f4b0a033eee0e.tar.gz
dotfiles-fad17a0bdacc93a2f0ec4097ee5f4b0a033eee0e.zip
loc(1df) errors to stderr, exit
Diffstat (limited to 'bin')
-rwxr-xr-xbin/loc3
1 files changed, 2 insertions, 1 deletions
diff --git a/bin/loc b/bin/loc
index 642a081c..20ef432e 100755
--- a/bin/loc
+++ b/bin/loc
@@ -1,6 +1,7 @@
#!/bin/sh
if [ "$#" -eq 0 ] ; then
- printf 'loc: Need a search term\n'
+ printf >&2 'loc: Need a search term\n'
+ exit 2
fi
for pat ; do
find . -name '*'"$pat"'*'