update ignore
This commit is contained in:
24
clear-log.bat
Normal file
24
clear-log.bat
Normal file
@@ -0,0 +1,24 @@
|
||||
@echo off
|
||||
setlocal enabledelayedexpansion
|
||||
|
||||
set "LOG_DIR=%~dp0src-tauri"
|
||||
set "FOUND=0"
|
||||
|
||||
if not exist "%LOG_DIR%" (
|
||||
echo Log directory not found: "%LOG_DIR%"
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
for %%F in ("%LOG_DIR%\program.log*") do (
|
||||
if exist "%%~fF" (
|
||||
type nul > "%%~fF"
|
||||
echo Cleared: %%~nxF
|
||||
set "FOUND=1"
|
||||
)
|
||||
)
|
||||
|
||||
if "%FOUND%"=="0" (
|
||||
echo No matching log files found in "%LOG_DIR%".
|
||||
)
|
||||
|
||||
endlocal
|
||||
Reference in New Issue
Block a user