Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @ECHO OFF
- REM A batch file for saving backups of the mod folders.
- REM Version 1.0, 13 October 2017, by dziban303 of https://worldofwarshipsskins.reddit.com
- REM This assumes you have 7Zip installed at it's default directory of C:\Program Files\7Zip.
- REM If you have it installed elsewhere, you must change the path on those two lines.
- if "%1"=="" goto :fail
- if not exist "%1" goto :wrong
- if "%2"=="f" goto :full
- if "%2"=="-f" goto :full
- echo You have chosen a partial backup with no DDS textures or PSD files. Use switch "f" for a full backup.
- set filename="%1 (no dds or psd).7z"
- "C:\Program Files\7-Zip\7z" a %filename% .\%1\* -xr!*.dds -xr!*.psd -mx=9
- if errorlevel 1 echo Looks like something went wrong. && goto :eof
- echo Done!
- goto :eof
- :full
- echo You have chosen a full backup.
- set filename="%1 (full).7z"
- "C:\Program Files\7-Zip\7z" a %filename% .\%1\* -mx=9
- if errorlevel 1 echo Looks like something went wrong. && goto :eof
- echo Done!
- goto :eof
- :fail
- echo Oops, you didn't enter any arguments.
- echo Usage: backupmods (mod folder) (f)
- echo Example: backupmods 0.6.9.1.1 -- Partial backup
- echo Example 2: backupmods 0.6.9.1.1 f -- Full backup
- echo Try again.
- goto :eof
- :wrong
- echo That folder (%1) doesn't exist.
- goto :eof
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement