Created
July 30, 2013 00:22
-
-
Save rbwestmoreland/6109070 to your computer and use it in GitHub Desktop.
Batch file date time parsing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
set year=%date:~10,4% | |
set month=%date:~4,2% | |
set day=%date:~7,2% | |
set hour=%time:~0,2% | |
set minute=%time:~3,2% | |
set second=%time:~6,2% | |
set millisecond=%time:~9,2% | |
echo %year% %month% %day% %hour% %minute% %second% %millisecond% | |
pause |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment