New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
Changeset 7023 for branches/UKMO/dev_r6393_CO6_package_trunk/NEMOGCM/NEMO/OPA_SRC/IOM/restart.F90 – NEMO

Ignore:
Timestamp:
2016-10-12T16:10:13+02:00 (8 years ago)
Author:
deazer
Message:

Include update for restart date labelling for rose cycling.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/UKMO/dev_r6393_CO6_package_trunk/NEMOGCM/NEMO/OPA_SRC/IOM/restart.F90

    r7019 r7023  
    2727   USE in_out_manager  ! I/O manager 
    2828   USE iom             ! I/O module 
     29   USE ioipsl, ONLY : ju2ymds    ! for calendar 
    2930   USE diurnal_bulk 
    3031    
     
    5758      !!---------------------------------------------------------------------- 
    5859      INTEGER, INTENT(in) ::   kt     ! ocean time-step 
     60      INTEGER             ::   iyear, imonth, iday 
     61      REAL (wp)           ::   zsec 
    5962      !! 
    6063      CHARACTER(LEN=20)   ::   clkt     ! ocean time-step deine as a character 
     
    8487      IF( kt == nitrst - 1 .OR. nstock == 1 .OR. ( kt == nitend .AND. .NOT. lrst_oce ) ) THEN 
    8588         IF( nitrst <= nitend .AND. nitrst > 0 ) THEN  
    86             ! beware of the format used to write kt (default is i8.8, that should be large enough...) 
    87             IF( nitrst > 999999999 ) THEN   ;   WRITE(clkt, *       ) nitrst 
    88             ELSE                            ;   WRITE(clkt, '(i8.8)') nitrst 
     89            IF ( ln_rstdate ) THEN 
     90               CALL ju2ymds( fjulday + rdt / rday, iyear, imonth, iday, zsec )            
     91               WRITE(clkt, '(i4.4,2i2.2)') iyear, imonth, iday 
     92            ELSE 
     93               ! beware of the format used to write kt (default is i8.8, that should be large enough...) 
     94               IF( nitrst > 999999999 ) THEN   ;   WRITE(clkt, *       ) nitrst 
     95               ELSE                            ;   WRITE(clkt, '(i8.8)') nitrst 
     96               ENDIF 
    8997            ENDIF 
    9098            ! create the file 
Note: See TracChangeset for help on using the changeset viewer.