File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -40,10 +40,12 @@ lnd_ts_for_ilamb={{ output }}/post/lnd/{{ ts_land_grid }}/cmip_ts/monthly/
4040atm_ts_for_ilamb={{ output }}/post/atm/{{ ts_atm_grid }}/cmip_ts/monthly/
4141# Go through the time series files for between year1 and year2,
4242# using a step size equal to the number of years per time series file
43- for year in ` seq ${Y1} {{ ts_num_years }} ${Y2} ` ;
43+ start_year=$( echo $Y1 | sed ' s/^0*//' )
44+ end_year=$( echo $Y2 | sed ' s/^0*//' )
45+ for year in ` seq $start_year {{ ts_num_years }} $end_year ` ;
4446do
45- start_year=` printf " %04d" ${year} `
4647 end_year_int=$(( ${start_year} + {{ ts_num_years }} - 1 ))
48+ start_year=` printf " %04d" ${year} `
4749 end_year=` printf " %04d" ${end_year_int} `
4850 echo " Copying files for ${start_year} to ${end_year} "
4951 cp -s ${lnd_ts_for_ilamb} /* _* _* _* _* _* _${start_year} ?? -${end_year} ?? .nc .
You can’t perform that action at this time.
0 commit comments