diff options
| author | Michael Peter Christen <mc@yacy.net> | 2026-01-01 23:58:10 +0100 |
|---|---|---|
| committer | Michael Peter Christen <mc@yacy.net> | 2026-01-01 23:58:10 +0100 |
| commit | 3ecb0b459ee8500aa721b4ee8804bbde6f5c9dc3 (patch) | |
| tree | 1014e196905b23125437c0f5e45cf725e86cf5be /startYACY.bat | |
| parent | c5801d3215a0969bcf90fb2d882775302cd92f19 (diff) | |
fixed windows installer; updated download path for java installer
Diffstat (limited to 'startYACY.bat')
| -rw-r--r-- | startYACY.bat | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/startYACY.bat b/startYACY.bat index 5b4dce28c..93602ea7b 100644 --- a/startYACY.bat +++ b/startYACY.bat @@ -2,8 +2,10 @@ title YaCy REM setting startup type for proper restart -if not exist DATA md DATA -echo . >DATA\yacy.noconsole +if "%YACY_DATA%"=="" set "YACY_DATA=%LOCALAPPDATA%\YaCy" +set "YACY_DATA_DIR=%YACY_DATA%\DATA" +if not exist "%YACY_DATA_DIR%" md "%YACY_DATA_DIR%" +echo . >"%YACY_DATA_DIR%\yacy.noconsole" Rem Setting the classpath Set CLASSPATH=lib\yacycore.jar @@ -14,8 +16,8 @@ set jms= set javacmd=-Xmx600m set priolvl=10 set priority=/BELOWNORMAL -if exist DATA\SETTINGS\httpProxy.conf GoTo :RENAMEINDEX -if exist DATA\SETTINGS\yacy.conf GoTo :GETSTARTOPTS +if exist "%YACY_DATA_DIR%\SETTINGS\httpProxy.conf" GoTo :RENAMEINDEX +if exist "%YACY_DATA_DIR%\SETTINGS\yacy.conf" GoTo :GETSTARTOPTS :STARTJAVA set javacmd=%javacmd% -Djava.awt.headless=true -Dsolr.directoryFactory=solr.MMapDirectoryFactory -Dfile.encoding=UTF-8 @@ -35,7 +37,7 @@ Rem commandline parameter added for -config option, like -config "port=8090" "ad Rem special parameter "adminAccount=admin:password" calculates and sets new admin-pwd Rem any parameter in yacy.conf can me modified this way (make sure to use correct upper/lower case) -start %priority% java %javacmd% -classpath %CLASSPATH% net.yacy.yacy %1 %2 %3 %4 %5 %6 %7 %8 %9 +start %priority% java %javacmd% -Dyacy.data="%YACY_DATA%" -classpath %CLASSPATH% net.yacy.yacy %1 %2 %3 %4 %5 %6 %7 %8 %9 Echo You can close the console safely now. @@ -43,18 +45,17 @@ GoTo :END Rem PUBLIC is now freeworld (r4575) :RENAMEINDEX -for /F "tokens=1,2 delims==" %%i in (DATA\SETTINGS\httpProxy.conf) do ( +for /F "usebackq tokens=1,2 delims==" %%i in ("%YACY_DATA_DIR%\SETTINGS\httpProxy.conf") do ( if "%%i"=="network.unit.name" set networkname=%%j ) if not defined networkname set networkname=PUBLIC -cd DATA\INDEX +pushd "%YACY_DATA_DIR%\INDEX" ren PUBLIC %networkname% -cd .. -cd .. +popd Rem This target is used to read java runtime parameters out of the yacy config file :GETSTARTOPTS -for /F "tokens=1,2 delims==" %%i in (DATA\SETTINGS\yacy.conf) do ( +for /F "usebackq tokens=1,2 delims==" %%i in ("%YACY_DATA_DIR%\SETTINGS\yacy.conf") do ( if "%%i"=="javastart_Xmx" set jmx=%%j if "%%i"=="javastart_priority" set priolvl=%%j ) |
