From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fee84,9343d3756c394320,start X-Google-Attributes: gidfee84,public From: William Li Subject: Shell script or command for future 'date' ? Date: 1996/12/13 Message-ID: <32B0912D.49A2@cincom.com>#1/1 X-Deja-AN: 203793116 distribution: inet cache-post-path: nachos.wr.com.au!unknown@199.18.4.161 content-type: text/plain; charset=big5 organization: Customer of World Reach Internet Access mime-version: 1.0 reply-to: wli@cincom.com newsgroups: comp.unix.osf.osf1 x-mailer: Mozilla 3.0Gold (Win95; I) Hi, I am new for shell programming and I wonder if someone could help me on the following problem. I have a DEC Alpha box with DEC UNIX 4.0 and I need to write a shell script (for both csh and ksh) which will generate an input card file for a program that runs periodically. This input card file contains only 1 line with the following format cm cd cy tm td ty <8 spaces> 7m 7d 7y where cm, cd, cy are current month, day, year resp., tm, td, ty are tomorrow's month, day, year resp. and 7m, 7d, 7y are month, day and year for 7 days later. I know the unix command - date +"%m %d %y", will give me the first part of the line but what about the rest of the line and how to concatenate the output. Can this be done easily by a shell script? Thanks in advanced for any help and/or info. Best regards, William