-sdel (Delete files after compression) switch



If -sdel switch is specified, 7-Zip deletes files after including to archive. So it works like moving files to archive.

7-Zip deletes files at the end of operation and only if archive was successfully created.


7z a a.7z *.txt -sdel

moves txt files from disk's directory to a.7z archive.

Commands that can be used with this switch

a (Add)