我想在使用Robocopy Log时避免使用目标文件夹的所有现有文件名和详细信息.
只想显示复制的文件列表及其详细信息.
因此,我可以通过避免日志中的现有文件详细信息来节省robocopy日志文件大小.
有没有选择可以避免它,请帮助解决这个问题
我看不出任何选择
记录选项:::
/L :: List only - don't copy, timestamp or delete any files.
/X :: report all eXtra files, not just those selected.
/V :: produce Verbose output, showing skipped files.
/TS :: include source file Time Stamps in the output.
/FP :: include Full Pathname of files in the output.
/BYTES :: Print sizes as bytes.
/NS :: No Size - don't log file sizes.
/NC :: No Class - don't log file classes.
/NFL :: No File List - don't log file names.
/NDL :: No Directory List - don't log directory names.
/NP :: No Progress - don't display percentage copied.
/ETA :: show Estimated Time of Arrival of copied files.
/LOG:file :: output status to LOG file (overwrite existing log).
/LOG+:file :: output status to LOG file (append to existing log).
/UNILOG:file :: output status to LOG file as UNICODE (overwrite existing log).
/UNILOG+:file :: output status to LOG file as UNICODE (append to existing log).
/TEE :: output to console window, as well as the log file.
/NJH :: No Job Header.
/NJS :: No Job Summary.
/UNICODE :: output status as UNICODE.
Run Code Online (Sandbox Code Playgroud)
Ans*_*ers 21
默认情况下,robocopy
仅记录文件夹和非现有/修改(即复制)文件.
New Dir 2 C:\Temp\a\
100% New File 0 bar.txt
100% New File 0 foo.txt
Run Code Online (Sandbox Code Playgroud)
您可以使用/ndl
开关禁止记录文件夹(在这种情况下,将列出复制的文件及其完整路径).
100% New File 0 C:\Temp\a\bar.txt
100% New File 0 C:\Temp\a\foo.txt
Run Code Online (Sandbox Code Playgroud)
只需修改foo.txt
并重新运行robocopy a b /ndl
就可以了
100% Newer 3 C:\Temp\a\foo.txt
Run Code Online (Sandbox Code Playgroud)
添加/njh
和/njs
删除输出中的标题和摘要.添加/np
以删除进度指示(输出行开头的百分比值).添加/xx
以删除额外文件的指示(仅存在于目标中但不存在于源文件夹中的文件):
C:\Temp>robocopy a b /njh /njs /ndl /np
*EXTRA File 0 C:\Temp\b\baz.txt
New File 0 C:\Temp\a\bar.txt
New File 0 C:\Temp\a\foo.txt
C:\Temp>echo "foo" >a\bar.txt
C:\Temp>robocopy a b /njh /njs /ndl /np /l
*EXTRA File 0 C:\Temp\b\baz.txt
Newer 3 C:\Temp\a\bar.txt
C:\Temp>robocopy a b /njh /njs /ndl /np /xx /l
Newer 8 C:\Temp\a\bar.txt
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
27667 次 |
最近记录: |