projects
/
ghc-hetmet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d54fc08
)
mkdirhier.sh now accepts -q, which makes it be quiet
author
Ian Lynagh
<igloo@earth.li>
Fri, 27 Jun 2008 23:35:28 +0000
(23:35 +0000)
committer
Ian Lynagh
<igloo@earth.li>
Fri, 27 Jun 2008 23:35:28 +0000
(23:35 +0000)
utils/mkdirhier/mkdirhier.sh
patch
|
blob
|
history
diff --git
a/utils/mkdirhier/mkdirhier.sh
b/utils/mkdirhier/mkdirhier.sh
index
3ae24b3
..
c6261f4
100644
(file)
--- a/
utils/mkdirhier/mkdirhier.sh
+++ b/
utils/mkdirhier/mkdirhier.sh
@@
-5,8
+5,16
@@
#
# Based on Noah Friedman's mkinstalldirs..
#
+
+quiet=no
errs=0
+if [ "$1" = "-q" ]
+then
+ shift
+ quiet=yes
+fi
+
for f in $*; do
parts=`echo ":$f" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'`
path="";
@@
-17,7
+25,10
@@
for f in $*; do
esac
if test ! -d "$path"; then
- echo "mkdir $path" 1>&2
+ if [ "$quiet" = "no" ]
+ then
+ echo "mkdir $path" 1>&2
+ fi
mkdir "$path" || lasterr=$?