Page Menu
Home
GnuPG
Search
Configure Global Search
Log In
Files
F35860133
mkinstalldirs
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Size
676 B
Subscribers
None
mkinstalldirs
View Options
#! /bin/sh
# mkinstalldirs --- make directory hierarchy
# Author: Noah Friedman <friedman@prep.ai.mit.edu>
# Created: 1993-05-16
# Public domain
# $Id$
errstatus
=
0
for
file
do
set
fnord
`
echo
":
$file
"
|
sed -ne
's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'
`
shift
pathcomp
=
for
d
do
pathcomp
=
"
$pathcomp$d
"
case
"
$pathcomp
"
in
-*
)
pathcomp
=
./
$pathcomp
;;
esac
if
test
! -d
"
$pathcomp
"
;
then
echo
"mkdir
$pathcomp
"
1
>
&
2
mkdir
"
$pathcomp
"
||
lasterr
=
$?
if
test
! -d
"
$pathcomp
"
;
then
errstatus
=
$lasterr
fi
fi
pathcomp
=
"
$pathcomp
/"
done
done
exit
$errstatus
# mkinstalldirs ends here
File Metadata
Details
Attached
Mime Type
text/x-shellscript
Expires
Sun, Feb 15, 3:46 PM (15 h, 23 m)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
bf/01/b4549eddec3aa92811fb60a5d303
Attached To
rG GnuPG
Event Timeline
Log In to Comment