Last active
August 29, 2015 14:17
-
-
Save wuzzzzaah/831f73eed5808b5f040f to your computer and use it in GitHub Desktop.
Appends timestamp to file
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
set dt=%date:~7,2%%date:~4,2%%date:~10,4%%time:~0,2%%time:~3,2%%time:~6,2% | |
set origFile=%1 | |
set noext=%origFile:~0,-4% | |
set ext=%origFile:~-4% | |
ren %1 %noext%%dt%%ext% |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
append_timestamp_to_file.bat sample.csv