File tree 2 files changed +9
-8
lines changed
2 files changed +9
-8
lines changed Original file line number Diff line number Diff line change @@ -14,6 +14,13 @@ ECFLOW_RUNNING=false
14
14
15
15
jobid=0
16
16
17
+ redirect_out_err () {
18
+ ( " $@ " 2>&1 1>&3 3>& - | tee err ) 3>&1 1>&2 | tee out
19
+ # The above shell redirection copies stdout to "out" and stderr to "err"
20
+ # while still sending them to stdout and stderr. It does this without
21
+ # relying on bash-specific extensions or non-standard OS features.
22
+ }
23
+
17
24
function compute_petbounds_and_tasks() {
18
25
19
26
# each test MUST define ${COMPONENT}_tasks variable for all components it is using
Original file line number Diff line number Diff line change @@ -25,13 +25,6 @@ remove_fail_test() {
25
25
rm -f " ${PATHRT} /fail_test_${TEST_ID} "
26
26
}
27
27
28
- redirect_out_err () {
29
- ( " $@ " 2>&1 1>&3 3>& - | tee err ) 3>&1 1>&2 | tee out
30
- # The above shell redirection copies stdout to "out" and stderr to "err"
31
- # while still sending them to stdout and stderr. It does this without
32
- # relying on bash-specific extensions or non-standard OS features.
33
- }
34
-
35
28
if [[ $# != 5 ]]; then
36
29
echo " Usage: $0 PATHRT RUNDIR_ROOT TEST_NAME TEST_ID COMPILE_ID"
37
30
exit 1
@@ -387,7 +380,8 @@ if [[ ${SCHEDULER} = 'none' ]]; then
387
380
388
381
ulimit -s unlimited
389
382
if [[ ${CI_TEST} = ' true' ]]; then
390
- redirect_out_err $( eval " ${OMP_ENV} " mpiexec -n " ${TASKS} " ./fv3.exe )
383
+ ( eval " ${OMP_ENV} " ;
384
+ redirect_out_err mpiexec -n " ${TASKS} " ./fv3.exe )
391
385
else
392
386
redirect_out_err mpiexec -n " ${TASKS} " ./fv3.exe
393
387
fi
You can’t perform that action at this time.
0 commit comments