分享我的findstr
解决方案:
%ZIP% a -tzip %FILE% %Folder% | findstr /I "archive everything"
因此,原始的14行输出为:
7-Zip 18.01 (x64) : Copyright (c) 1999-2018 Igor Pavlov : 2018-01-28
Scanning the drive:
4 folders, 13 files, 88957 bytes (87 KiB)
Creating archive: Releases\Archive.zip
Add new data to archive: 4 folders, 13 files, 88957 bytes (87 KiB)
Files read from disk: 13
Archive size: 33913 bytes (34 KiB)
Everything is Ok
缩小到4行:
Creating archive: Releases\Archive.zip
Add new data to archive: 4 folders, 13 files, 88957 bytes (87 KiB)
Archive size: 33912 bytes (34 KiB)
Everything is Ok
它只会缩小sOut,警告和错误会转到sErr,因此您仍然会看到它们