Skip to content

Commit a4c885c

Browse files
Adding support for the year 2024
1 parent d9c411c commit a4c885c

File tree

1 file changed

+6
-6
lines changed
  • var/repos/builtin/recipes/eccc-casr

1 file changed

+6
-6
lines changed

var/repos/builtin/recipes/eccc-casr/casr.sh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -250,17 +250,17 @@ get_shifted_date() {
250250
# Assure the start-date is not before 1980-01-01
251251
startDateInt=$(date --date="$startDate" +"%Y%m%d%H")
252252
if [[ $startDateInt -lt "1979123113" ]]; then
253-
echo "$(logDate)$(basename $0): WARNING! The date range of the dataset is between 1979-12-31T13:00:00 and 2023-12-31T12:00:00"
253+
echo "$(logDate)$(basename $0): WARNING! The date range of the dataset is between 1979-12-31T13:00:00 and 2024-12-31T12:00:00"
254254
echo "$(logDate)$(basename $0): WARNING! \`start-date\` is set to 1979-12-31 13:00:00"
255255
startDate="1979-12-31T13:00:00"
256256
fi
257257

258-
# Assure the end-date is not beyond 2023-12-30
258+
# Assure the end-date is not beyond 2024-12-31
259259
endDateInt=$(date --date="$endDate" +"%Y%m%d%H")
260-
if [[ $endDateInt -gt "2023123112" ]]; then
261-
echo "$(logDate)$(basename $0): WARNING! The date range of the dataset is between 1979-12-31T13:00:00 and 2023-12-31T12:00:00"
262-
echo "$(logDate)$(basename $0): WARNING! \`end-date\` is set to 2023-12-31 12:00:00"
263-
endDate="2023-12-31T12:00:00"
260+
if [[ $endDateInt -gt "2024123112" ]]; then
261+
echo "$(logDate)$(basename $0): WARNING! The date range of the dataset is between 1979-12-31T13:00:00 and 2024-12-31T12:00:00"
262+
echo "$(logDate)$(basename $0): WARNING! \`end-date\` is set to 2024-12-31 12:00:00"
263+
endDate="2024-12-31T12:00:00"
264264
fi
265265

266266
# Date values for iterations over dataset files

0 commit comments

Comments
 (0)