/* warpdate.rexx */ /* adjust current time so battclock can keep GMT */ /* CONFIGURE HERE */ /* number of minutes short of GMT */ off = 300 /* STOP CONFIGURING */ /* do not change day by default */ changeday = '' /* find minutes after midnight */ mins = time('m') /* adjust minutes */ mins = mins - off /* if we go back a day, adjust minutes and changeday flag */ if mins < 0 then do mins = 1440 + mins changeday = 'yesterday' end /* if we go ahead a day, adjust minutes and changeday flag */ if mins > 1439 then do mins = 1440 - mins changeday = 'tomorrow' end /* extract new hour from minutes; set minutes to minutes since hour */ hour = trunc(mins / 60) mins = mins - (hour * 60) /* update seconds */ tmp = time('m') secs = time('s') secs = secs - (tmp * 60) /* create an amigados 'date' command */ datestr = 'date 'changeday' 'hour':'mins':'secs /* and change the clock */ address command datestr /* notify of change */ if changeday == '' then do changeday = 'today'