Skip to content

Commit 9d2c18d

Browse files
committed
fixup! Fix Windows support to not break Linux/Mac support
1 parent 3f1af98 commit 9d2c18d

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

scripts/startNeo4j.sh

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,6 @@ fi
4545
# Include operation system function to for example detect Windows.
4646
source "${SCRIPTS_DIR}/operatingSystemFunctions.sh"
4747

48-
scriptExtension=$(ifWindows ".bat" "")
49-
echo "startNeo4j: Using scriptExtension ${scriptExtension} for Windows."
50-
5148
# Include functions to check or wait for the database to be ready
5249
source "${SCRIPTS_DIR}/waitForNeo4jHttpFunctions.sh"
5350

@@ -71,7 +68,7 @@ if [[ ${isDatabaseReady} == "false" ]]; then
7168

7269
# Start Neo4j using a temporary NEO4J_HOME environment variable that points to the current installation
7370
if isWindows; then
74-
neo4jStartCommand="${NEO4J_BIN_WINDOWS}\neo4j${scriptExtension} console --verbose"
71+
neo4jStartCommand="${NEO4J_BIN_WINDOWS}\neo4j.bat console --verbose"
7572
# On Windows it is necessary to take the absolute full qualified path to Neo4j for the environment variable NEO4J_HOME.
7673
# It also works without any environment variable but this would likely lead to ambiguity problems when there are multiple Neo4j instances installed.
7774
# If the path is wrong content-wise this leads to a ClassNotFoundException.
@@ -85,7 +82,7 @@ if [[ ${isDatabaseReady} == "false" ]]; then
8582

8683
cmd //c start cmd //v //k "${windowsCommand}"
8784
else
88-
NEO4J_HOME=${NEO4J_DIR} | ${NEO4J_BIN}/neo4j${scriptExtension} start --verbose
85+
NEO4J_HOME=${NEO4J_DIR} ${NEO4J_BIN}/neo4j start --verbose
8986
fi
9087

9188
waitUntilDatabaseIsQueryable

scripts/stopNeo4j.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ else
5555
echo "stopNeo4j: IMPORTANT: Please close the console window manually where neo4j-${NEO4J_EDITION}-${NEO4J_VERSION} is running on Windows."
5656
else
5757
# Stop Neo4j using a temporary NEO4J_HOME environment variable that points to the current installation
58-
NEO4J_HOME=${NEO4J_DIR} | ${NEO4J_BIN}/neo4j stop
58+
NEO4J_HOME=${NEO4J_DIR} ${NEO4J_BIN}/neo4j stop
5959
fi
6060
fi
6161

0 commit comments

Comments
 (0)