Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- :: To use, drag a folder on top of the .bat file.
- :: We assume that you have 7-Zip x64 installed to its default location.
- @echo off
- SET "PATH=C:\Program Files\7-Zip\;%PATH%"
- echo.Delete uncompressed files when done?
- set /p delfiles=^[Y/N^]:
- FOR /R %1 %%I IN (*.*) DO (
- 7z a -tbzip2 -mx=9 "%%I.bz2" "%%I"
- IF /I "%delfiles%"=="y" (
- DEL /Q /S "%%I"
- )
- )
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement