Changeset 5750 in orxonox.OLD for trunk/mkinstalldirs
- Timestamp:
- Nov 24, 2005, 12:13:22 AM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/mkinstalldirs
r5479 r5750 2 2 # mkinstalldirs --- make directory hierarchy 3 3 4 scriptversion=2005-0 6-29.224 scriptversion=2005-02-02.21 5 5 6 6 # Original author: Noah Friedman <friedman@prep.ai.mit.edu> … … 13 13 14 14 errstatus=0 15 dirmode= 15 dirmode="" 16 16 17 17 usage="\ … … 104 104 for file 105 105 do 106 case $file in 107 /*) pathcomp=/ ;; 108 *) pathcomp= ;; 109 esac 110 oIFS=$IFS 111 IFS=/ 112 set fnord $file 106 set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'` 113 107 shift 114 IFS=$oIFS115 108 109 pathcomp= 116 110 for d 117 111 do 118 test "x$d" = x && continue 119 120 pathcomp=$pathcomp$d 112 pathcomp="$pathcomp$d" 121 113 case $pathcomp in 122 114 -*) pathcomp=./$pathcomp ;; … … 133 125 if test ! -z "$dirmode"; then 134 126 echo "chmod $dirmode $pathcomp" 135 lasterr= 127 lasterr="" 136 128 chmod "$dirmode" "$pathcomp" || lasterr=$? 137 129 … … 143 135 fi 144 136 145 pathcomp= $pathcomp/137 pathcomp="$pathcomp/" 146 138 done 147 139 done
Note: See TracChangeset
for help on using the changeset viewer.