ab7fdf50c5
git-svn-id: https://svn.code.sf.net/p/speed-dreams/code/trunk@4442 30fe4595-0a0c-4342-8851-515496e4dcbd Former-commit-id: 2f7d8d5adecc2d0e5d0c5160d8a9eea3d1a98a26 Former-commit-id: 3753a3e3a2db28d069bd8d0e2ee320a7b6045a8d
25 lines
400 B
Bash
Executable file
25 lines
400 B
Bash
Executable file
#!/bin/bash
|
|
#
|
|
# Set up path in Speed Dreams mod tools startup scripts.
|
|
|
|
shopt -s extglob
|
|
|
|
function updatepath () {
|
|
fn=${SETUP_INSTALLPATH}/$1
|
|
|
|
# rip off last "/"
|
|
ip=${SETUP_INSTALLPATH/%\//}
|
|
|
|
# replace all "/" with "\/" to use with regexp.
|
|
fn2=${ip//\//\\\/}
|
|
|
|
ed -s $fn <<EOF
|
|
,s/@prefix@/$fn2/g
|
|
,wq
|
|
EOF
|
|
}
|
|
|
|
for f in sd-accc sd-nfs2ac sd-nfsperf sd-texmapper sd-trackgen;
|
|
do updatepath $f ;
|
|
done
|
|
|