Skip to content
This repository was archived by the owner on Aug 18, 2020. It is now read-only.

Commit 1d07d17

Browse files
authored
Update install.bat
1 parent e7496bc commit 1d07d17

File tree

1 file changed

+25
-13
lines changed

1 file changed

+25
-13
lines changed

install.bat

Lines changed: 25 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -11,20 +11,30 @@ IF "%MISSING_REQUIREMENT%"=="true" (
1111
ECHO * All requirements are installed
1212
)
1313

14+
SET "npm=true"
1415
SET "yarn=true"
1516
CALL :check_optional_requirement yarn
1617
IF "%MISSING_REQUIREMENT%"=="true" (
17-
SET "MISSING_REQUIREMENT=false"
18-
CALL :check_optional_requirement npm
19-
IF "%MISSING_REQUIREMENT%"=="true" (
20-
ECHO ! NPM or yarn is needed to set up webui
21-
PAUSE
22-
exit /b
23-
) ELSE (
24-
SET "yarn=false"
25-
)
18+
ECHO * Note: Yarn is not installed.
19+
SET "yarn=false"
2620
)
2721

22+
set "MISSING_REQUIREMENT=false"
23+
CALL :check_optional_requirement npm
24+
IF "%MISSING_REQUIREMENT%"=="true" (
25+
ECHO * Note: npm is not installed.
26+
SET "npm=false"
27+
)
28+
29+
IF "%npm%"=="false" (
30+
IF "%yarn%"=="false" (
31+
ECHO ! NPM or yarn is needed to set up webui
32+
PAUSE
33+
exit /b
34+
)
35+
)
36+
37+
2838
CALL :check_folder chatoverflow https://github.com/codeoverflow-org/chatoverflow chatoverflow
2939
CALL :check_folder chatoverflow/api https://github.com/codeoverflow-org/chatoverflow-api chatoverflow/api
3040
CALL :check_folder chatoverflow/gui https://github.com/codeoverflow-org/chatoverflow-gui chatoverflow/gui
@@ -35,23 +45,25 @@ cd chatoverflow/
3545
SET "MISSING_REQUIREMENT=false"
3646
CALL :check_optional_requirement sbt
3747
IF "%MISSING_REQUIREMENT%"=="true" (
38-
echo ! We would love to set the project up for you, but it seems like you don't have sbt installed.
39-
echo ! Please install sbt and execute $ sbt ';update;fetch;update'
40-
echo ! Or follow the guide at https://github.com/codeoverflow-org/chatoverflow/wiki/Installation
48+
ECHO ! We would love to set the project up for you, but it seems like you don't have sbt installed.
49+
ECHO ! Please install sbt and execute $ sbt ';update;fetch;update'
50+
ECHO ! Or follow the guide at https://github.com/codeoverflow-org/chatoverflow/wiki/Installation
4151
) ELSE (
4252
ECHO * Found sbt.
4353
sbt ";update;fetch;update"
4454
)
4555

4656
cd gui/
4757

58+
ECHO * Installing GUI (this may take a while...)
59+
4860
IF "%yarn%"=="true" (
4961
yarn
5062
) ELSE (
5163
npm install
5264
)
5365

54-
echo * Success! You can now open the project in IntelliJ (or whatever IDE you prefer)
66+
ECHO * Success! You can now open the project in IntelliJ (or whatever IDE you prefer)
5567

5668

5769
PAUSE

0 commit comments

Comments
 (0)