feat: 统一应用配置和内容过滤规则
This commit is contained in:
+5
-9
@@ -29,14 +29,10 @@ if not exist "%LIBCLANG_PATH%\libclang.dll" (
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
if not exist "%PROJECT_ROOT%\dht-search.toml" (
|
||||
echo [INFO] Creating local configuration from template
|
||||
copy /Y "%PROJECT_ROOT%\dht-search.example.toml" "%PROJECT_ROOT%\dht-search.toml" >nul
|
||||
if errorlevel 1 (
|
||||
echo [ERROR] Failed to create dht-search.toml
|
||||
pause
|
||||
exit /b 1
|
||||
)
|
||||
if not exist "%PROJECT_ROOT%\config.toml" (
|
||||
echo [ERROR] config.toml was not found
|
||||
pause
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
if not exist "%WEB_DIR%\node_modules" (
|
||||
@@ -70,7 +66,7 @@ powershell -NoProfile -ExecutionPolicy Bypass -Command ^
|
||||
" }" ^
|
||||
"}" ^
|
||||
"try {" ^
|
||||
" $backend = Start-Process -FilePath 'cargo' -ArgumentList @('run','-p','dht-search','--bin','dht-search','--','--config','dht-search.toml') -WorkingDirectory $env:PROJECT_ROOT -NoNewWindow -PassThru;" ^
|
||||
" $backend = Start-Process -FilePath 'cargo' -ArgumentList @('run','-p','dht-search','--bin','dht-search','--','--config','config.toml') -WorkingDirectory $env:PROJECT_ROOT -NoNewWindow -PassThru;" ^
|
||||
" $web = Start-Process -FilePath 'bun' -ArgumentList @('--bun','run','dev','--','--host','127.0.0.1') -WorkingDirectory $env:WEB_DIR -NoNewWindow -PassThru;" ^
|
||||
" while (-not $backend.HasExited -and -not $web.HasExited) { Start-Sleep -Milliseconds 250 }" ^
|
||||
"} finally {" ^
|
||||
|
||||
Reference in New Issue
Block a user