General discussion

Locked

shell script date

By adrian_buzea ·
How can I use the current (system)date as a variable in a NT shell script?

This conversation is currently closed to new comments.

1 total post (Page 1 of 1)  
| Thread display: Collapse - | Expand +

All Comments

Collapse -

shell script date

by WorldOfZeus In reply to shell script date

Try the following: -

for /f "tokens=2" %%7 in ('date /t') do set DATE_DAY=%%7
for /f %%7 in ('echo %date_day:/=%') do set DATE_DAY=%%7

Hope it helps

Rgds,

Zeus

Back to Windows Forum
1 total post (Page 1 of 1)  

Related Discussions

Operating Systems Forums