June 28th, 2016, 6:05
Photos
|__2010
|_2010 January
| |_John's Birthday
| |_Paris
|_2010 February
|_...
|__2011June 28th, 2016, 7:24
June 28th, 2016, 8:13
June 28th, 2016, 9:06
"Photos\2008\03. March 2008\"June 28th, 2016, 16:45
June 28th, 2016, 17:28
C:\dir /?
Displays a list of files and subdirectories in a directory.
DIR [drive:][path][filename] [/P] [/W] [/A[[:]attributes]]
[/O[[:]sortorder]] [/S] [/B] [/L] [/V] [/4]
[drive:][path][filename]
Specifies drive, directory, and/or files to list.
(Could be enhanced file specification or multiple filespecs.)
/P Pauses after each screenful of information.
/W Uses wide list format.
/A Displays files with specified attributes.
attributes D Directories R Read-only files
H Hidden files A Files ready for archiving
S System files - Prefix meaning not
/O List by files in sorted order.
sortorder N By name (alphabetic) S By size (smallest first)
E By extension (alphabetic) D By date & time (earliest first)
G Group directories first - Prefix to reverse order
A By Last Access Date (earliest first)
/S Displays files in specified directory and all subdirectories.
/B Uses bare format (no heading information or summary).
/L Uses lowercase.
/V Verbose mode.
/4 Displays year with 4 digits (ignored if /V also given).
Switches may be preset in the DIRCMD environment variable. Override
preset switches by prefixing any switch with - (hyphen)--for example, /-W.June 29th, 2016, 4:59
@echo off
rem X: is the clone drive
for /F %%i in ('dir X:\[*] /ad /b /s') do (
rem Look for subdirectories named 2000, 2001, 2002, .... 2016
for /L %%j in (2000,1,2016) do (
dir "%%i\" /b /ad | find "%%j"
rem Write the rename commands to batfile.txt
if not errorlevel 1 (
echo ren "%%i" %%j >> batfile.txt
goto :nexti
)
)
:nexti
)June 29th, 2016, 17:24
Powered by phpBB © phpBB Group.