1 | @echo off
|
---|
2 | pushd "%CD%"
|
---|
3 | CD /D "%~dp0"
|
---|
4 | d
|
---|
5 | set extdesc=the Solr Extension
|
---|
6 |
|
---|
7 | :: The port Jetty runs on:
|
---|
8 | set SOLR_JETTY_PORT=8983
|
---|
9 |
|
---|
10 | :: The port Jetty listens on for a "stop" command
|
---|
11 | set JETTY_STOP_PORT=8079
|
---|
12 |
|
---|
13 | if "%OS%" == "Windows_NT" goto WinNT
|
---|
14 | if "%OS%" == "" goto Win95
|
---|
15 | if "%GSDLLANG%" == "en" echo Setup failed - your PATH has not been set
|
---|
16 | if "%GSDLLANG%" == "es" echo No se pudo realizar la configuraci¢n - no se ha establecido la RUTA.
|
---|
17 | if "%GSDLLANG%" == "fr" echo Echc de l'installation - votre variable PATH n'a pas t ajuste
|
---|
18 | if "%GSDLLANG%" == "ru" echo áâ ®¢ª ¥ 〠« áì - ¥ ¡ë« ãáâ ®¢«¥
|
---|
19 | goto End
|
---|
20 |
|
---|
21 | :WinNT
|
---|
22 | set GEXT_SOLR=%CD%
|
---|
23 | set PATH=%GEXT_SOLR%\bin\script;%PATH%
|
---|
24 | set PATH=%GEXT_SOLR%\lib;%PATH%
|
---|
25 | set GS_CP_SET=yes
|
---|
26 | goto Success
|
---|
27 |
|
---|
28 | :Win95
|
---|
29 | if "%1" == "SetEnv" goto Win95Env
|
---|
30 | REM We'll invoke a second copy of the command processor to make
|
---|
31 | REM sure there's enough environment space
|
---|
32 | COMMAND /E:2048 /K %0 SetEnv
|
---|
33 | goto End
|
---|
34 |
|
---|
35 | :Win95Env
|
---|
36 | set GEXT_SOLR=%CD%
|
---|
37 | set PATH="%GEXT_SOLR%\bin\script";"%PATH%"
|
---|
38 | set PATH="%GEXT_SOLR%\lib";"%PATH%"
|
---|
39 | set GS_CP_SET=yes
|
---|
40 | goto Success
|
---|
41 |
|
---|
42 | :Success
|
---|
43 |
|
---|
44 | set fulldir=%~dp0
|
---|
45 |
|
---|
46 | :: strip off everything up to (and including) ext dir
|
---|
47 | set extdir=%fulldir:*ext\=%
|
---|
48 |
|
---|
49 | :: remove trailing slash
|
---|
50 | set extdir=%extdir:\=%
|
---|
51 |
|
---|
52 | setlocal enabledelayedexpansion
|
---|
53 | if "x%GSDL3EXTS%" == "x" (
|
---|
54 | set GSDL3EXTS=!extdir!
|
---|
55 | ) else (
|
---|
56 | set GSDL3EXTS=!GSDL3EXTS!:!extdir!
|
---|
57 | )
|
---|
58 | endlocal & set GSDL3EXTS=%GSDL3EXTS%
|
---|
59 |
|
---|
60 | echo +Your environment is now setup for %extdesc%
|
---|
61 |
|
---|
62 | :: Back to delayed expansion to avoid problems with environment
|
---|
63 | :: variables with brackets in them, such as "Program Files (x86)"
|
---|
64 |
|
---|
65 | echo ++Solr/Jetty server will run on port %SOLR_JETTY_PORT% (+ port %JETTY_STOP_PORT% for shutdown command)"
|
---|
66 | echo --These port values can be changed by editing:
|
---|
67 | echo -- %0
|
---|
68 |
|
---|
69 |
|
---|
70 |
|
---|
71 | :End
|
---|
72 |
|
---|
73 | popd |
---|