- Timestamp:
- 2016-10-27T17:37:22+02:00 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2016/dev_r6393_NOC_WAD/NEMOGCM/TOOLS/MISCELLANEOUS/make_usp_tar.sh
r7117 r7148 116 116 if [ $remfile == 'create_directory' ] ;then 117 117 mkdir $locfile 118 echo $remfile " " $locfile >> local .ctl118 echo $remfile " " $locfile >> local_template.ctl 119 119 else 120 120 wget $remfile -O $locfile 121 121 remfile=$(echo $remfile | sed -e "s;.*$locfile;SET_LOCAL_DIRECTORY_HERE/$locfile;") 122 echo $remfile " " $locfile >> local .ctl122 echo $remfile " " $locfile >> local_template.ctl 123 123 fi 124 124 done … … 134 134 #---------------------------------------------------------------- 135 135 # 136 grep -v "$2 " $1 > uspcfg_local .txt136 grep -v "$2 " $1 > uspcfg_local_template.txt 137 137 # 138 138 #---------------------------------------------------------------- … … 140 140 #---------------------------------------------------------------- 141 141 # 142 cat cfg.tmp | sed -e "s;http.*$;SET_LOCAL_DIRECTORY_HERE/local.ctl;" >> uspcfg_local .txt142 cat cfg.tmp | sed -e "s;http.*$;SET_LOCAL_DIRECTORY_HERE/local.ctl;" >> uspcfg_local_template.txt 143 143 # 144 144 # … … 161 161 # Edit the local.ctl file to set the local directory path 162 162 # 163 ed - local.ctl << EOFA 164 g/SET_LOCAL_DIRECTORY_HERE/s;SET_LOCAL_DIRECTORY_HERE;\$basedir; 165 w 166 q 167 EOFA 163 sed -e "s;SET_LOCAL_DIRECTORY_HERE;\$basedir;" local_template.ctl > local.ctl 168 164 # 169 165 # Edit the uspcfg_local.txt file to set the local directory path 170 166 # 171 ed - uspcfg_local.txt << EOFB 172 /SET_LOCAL_DIRECTORY_HERE/s;SET_LOCAL_DIRECTORY_HERE;\$basedir; 173 w 174 q 175 EOFB 167 sed -e "s;SET_LOCAL_DIRECTORY_HERE;\$basedir;" uspcfg_local_template.txt > uspcfg_local.txt 168 # 169 # Install local versions in the named CONFIG directory 170 # 176 171 if [ -f \$confdir/uspcfg.txt ] && [ ! -L \$confdir/uspcfg.txt ]; then 177 172 mv \$confdir/uspcfg.txt \$confdir/uspcfg_remote.txt … … 196 191 fi 197 192 } 193 export -f wget 198 194 EOF 199 195 #---------------------------------------------------------------- … … 217 213 fi 218 214 } 215 export -f wget 219 216 EOFC 220 217 #----------------------------------------------------------------
Note: See TracChangeset
for help on using the changeset viewer.