Last change
on this file since 3727 was
2185,
checked in by acosce, 11 years ago
|
Add some script for batch submission of surpack tools
|
-
Property svn:executable set to
*
|
File size:
648 bytes
|
Line | |
---|
1 | #!/bin/bash |
---|
2 | |
---|
3 | |
---|
4 | NewSimu=$( cat param.txt) |
---|
5 | OldSimu=${NewSimu}.BP |
---|
6 | |
---|
7 | for FullFile in $( find ${OldSimu} -type f -print ) |
---|
8 | do |
---|
9 | FileName=$( basename ${FullFile} | sed "s=/$==" | sed "s=^/==" ) |
---|
10 | ShortDir=$( dirname ${FullFile} | sed "s=${OldSimu}==" | sed "s=/$==" | sed "s=^/==" ) |
---|
11 | |
---|
12 | echo ${FullFile} ${NewSimu}/${ShortDir}/${FileName} |
---|
13 | mkdir -p ${NewSimu}/${ShortDir} |
---|
14 | mv ${FullFile} ${NewSimu}/${ShortDir}/${FileName} |
---|
15 | done |
---|
16 | |
---|
17 | |
---|
18 | find ${OldSimu} -type d -empty | sort -r | xargs -r rmdir --ignore-fail-on-non-empty -p |
---|
19 | |
---|
20 | |
---|
21 | # for FullDir in $( find ${OldSimu} -type d -empty -print ) |
---|
22 | # do |
---|
23 | # echo ${FullDir} |
---|
24 | # rmdir ${FullDir} |
---|
25 | # done |
---|
26 | |
---|
27 | |
---|
Note: See
TracBrowser
for help on using the repository browser.