From 8a75f94bbbf2e2a0574883a61f0ef04bc5855c33 Mon Sep 17 00:00:00 2001 From: Yasuhiro Matsumoto Date: Thu, 30 Jan 2020 19:07:31 +0900 Subject: Fix configDir of eclipse-jdt-ls Fixes #123 --- installer/install-eclipse-jdt-ls.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'installer/install-eclipse-jdt-ls.sh') diff --git a/installer/install-eclipse-jdt-ls.sh b/installer/install-eclipse-jdt-ls.sh index 7a99874..86528d9 100755 --- a/installer/install-eclipse-jdt-ls.sh +++ b/installer/install-eclipse-jdt-ls.sh @@ -7,12 +7,19 @@ curl -o lombok.jar 'https://projectlombok.org/downloads/lombok.jar' tar xvf jdt-language-server-latest.tar.gz rm jdt-language-server-latest.tar.gz +osType="\$(uname -s)" +case "\${osType}" in + Darwin*) configDir=config_mac;; + Linux*) configDir=config_linux;; + *) configDir=config_linux +esac + cat < eclipse-jdt-ls #!/usr/bin/env bash DIR=\$(cd \$(dirname \$0); pwd) LAUNCHER=\$(ls \$DIR/plugins/org.eclipse.equinox.launcher_*.jar) -java -Declipse.application=org.eclipse.jdt.ls.core.id1 -Dosgi.bundles.defaultStartLevel=4 -Declipse.product=org.eclipse.jdt.ls.core.product -Dlog.protocol=true -Dlog.level=ALL -noverify -Xmx1G -javaagent:\$DIR/lombok.jar -Xbootclasspath/a:\$DIR/lombok.jar -jar \$LAUNCHER -configuration \$DIR/config_linux -data \$DIR/data +java -Declipse.application=org.eclipse.jdt.ls.core.id1 -Dosgi.bundles.defaultStartLevel=4 -Declipse.product=org.eclipse.jdt.ls.core.product -Dlog.protocol=true -Dlog.level=ALL -noverify -Xmx1G -javaagent:\$DIR/lombok.jar -Xbootclasspath/a:\$DIR/lombok.jar -jar \$LAUNCHER -configuration \$DIR/$configDir -data \$DIR/data EOF chmod +x eclipse-jdt-ls -- cgit v1.2.3-54-g00ecf