mirror of
https://github.com/horsicq/Detect-It-Easy.git
synced 2026-06-24 01:54:08 +00:00
Create db_compress.cmd
This commit is contained in:
parent
46579ea559
commit
5ba69c65c0
1 changed files with 28 additions and 0 deletions
28
db_compress.cmd
Normal file
28
db_compress.cmd
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
:: Detect It Easy databases compressor for Windows (NTFS)
|
||||
:: Coded by DosX, https://github.com/DosX-dev
|
||||
|
||||
@echo off
|
||||
|
||||
call :compact_it "db"
|
||||
call :compact_it "db_extra"
|
||||
call :compact_it "db_custom"
|
||||
|
||||
exit /b 0
|
||||
|
||||
:compact_it
|
||||
set "path_to_dir=%~1"
|
||||
if not exist "%path_to_dir%" (
|
||||
echo "%path_to_dir%" not found!
|
||||
exit /b 1
|
||||
)
|
||||
pushd "%path_to_dir%"
|
||||
"%windir%\system32\compact.exe" "*" /C /S /F /I /A /Q /EXE:LZX >nul
|
||||
if "%errorlevel%" == "0" (
|
||||
echo [V] "%path_to_dir%" compressed!
|
||||
) else (
|
||||
echo [X] "%path_to_dir%" unable to compress!
|
||||
)
|
||||
popd
|
||||
set "path_to_dir="
|
||||
|
||||
exit /b 0
|
||||
Loading…
Add table
Add a link
Reference in a new issue