Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

time stamp and moving files

Status
Not open for further replies.

mikeboz

MIS
May 18, 2000
41
0
0
US
I want to write a script (bat) that will copy all files newer than a given date and then time stamp all of the files at the original location to the current date.

Any suggestions?
 
A standard unix command TOUCH does just that, set files to the current date. It has been ported to DOS and included with several packages. It came with most Borland programming packages for DOS ; you should be able to find a version somewhere, search for touch.exe.

Heh, just found one here :
 
actually I found the following:

copy /B *+,,

Anyone care to explain the '+,,' ?

This command will run thru all the files in the directory and basically touch them.

Now, when I check back to the directory I want to copy all of the files as of the last 'touching'?

Any suggestions?

Thanks,
mikeb
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top