cedadev / wflogger

Workflow logging utilities (for JASMIN and LOTUS)
BSD 2-Clause "Simplified" License
0 stars 0 forks source link

Recommend usage with "timeout 3 ...cmd... args" and Env variable? #6

Open agstephens opened 2 years ago

agstephens commented 2 years ago
#!/bin/bash
# SLURM directives

USE_WFLOGGER=1

if [ $USE_WFLOGGER ]; then
     log....
fi

..do something...

if [ $USE_WFLOGGER ]; then
     log....
fi

..do something...

if [ $USE_WFLOGGER ]; then
     log....
fi

Or maybe use:

$USE_WFLOGGER && log...
agstephens commented 2 years ago

Wrap the timeout call inside the wflog script.