diff options
| author | Bjoern Brandenburg <bbb@dhcp11667.dhcp.unc.edu> | 2009-01-12 10:18:14 -0500 |
|---|---|---|
| committer | Bjoern Brandenburg <bbb@dhcp11667.dhcp.unc.edu> | 2009-01-12 10:18:14 -0500 |
| commit | 10514785b2690b443610afef558de6f7d4f72dd9 (patch) | |
| tree | d444afd148c39f6a81dda801d61f007df28a28eb | |
| parent | 9944aa4f8f25b7f262b68331875b49e9f5e384cd (diff) | |
skip empty files
| -rwxr-xr-x | plot_ecrts | 5 |
1 files changed, 5 insertions, 0 deletions
| @@ -38,6 +38,11 @@ function plot_file { | |||
| 38 | STRIPPED=`get_tmp_file` | 38 | STRIPPED=`get_tmp_file` |
| 39 | # remove comments for Gnuplot | 39 | # remove comments for Gnuplot |
| 40 | egrep -v '^#' $FILE > $STRIPPED | 40 | egrep -v '^#' $FILE > $STRIPPED |
| 41 | if [ ! -s $STRIPPED ] | ||
| 42 | then | ||
| 43 | echo "Skipping $FILE since there wasn't any data to be found. " | ||
| 44 | return | ||
| 45 | fi | ||
| 41 | # decode file name | 46 | # decode file name |
| 42 | PARAMS= | 47 | PARAMS= |
| 43 | for KV in `echo $NAME | sed -e 's/_/ /g'` | 48 | for KV in `echo $NAME | sed -e 's/_/ /g'` |
