forked from oskariorg/oskari-frontend
-
Notifications
You must be signed in to change notification settings - Fork 0
/
init.bat
40 lines (32 loc) · 867 Bytes
/
init.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
@ECHO OFF
cls
set binpath=%CD%
set binpath=%binpath%/tools/node_modules/.bin
:installpackages
echo Installing tools
cd tools
echo Please input http proxy url
echo (e.g. http://proxy.example.com:8080) or press ENTER to skip
set /p TEMPHTTPPROXY=PROXY URL:
if not defined TEMPHTTPPROXY (goto npminstall)
call npm config set proxy %TEMPHTTPPROXY%
echo Please input https proxy url
echo (e.g. https://proxy.example.com:8080) or press ENTER to skip
set /p TEMPHTTPSPROXY=PROXY URL:
if not defined TEMPHTTPSPROXY (goto npminstall)
call npm config set https-proxy %TEMPHTTPSPROXY%
REM clear TEMPHTTP(S)PROXY variables
set TEMPHTTPPROXY=
set TEMPHTTPSPROXY=
:npminstall
call npm install
cd ..
goto binexistcheck
:binexistcheck
if exist %binpath% (goto binexists) else (goto installpackages)
goto end
:binexists
echo init is done.
echo running start
begin.bat
@ECHO ON