I broke up with neovim....vim is my best friend now

This commit is contained in:
LinlyBoi
2023-04-30 08:14:07 +03:00
parent 0d185449c5
commit 4a4a6b1e81
5245 changed files with 468325 additions and 25 deletions

View File

@@ -0,0 +1,10 @@
#!/bin/sh
# Usage
# $ go_install [GO_GET_URLPATH]
set -e
GOPATH=$(pwd) GOBIN=$(pwd) GO111MODULE=on go install -v "$1"
GOPATH=$(pwd) GO111MODULE=on go clean -modcache
rm -rf src pkg 2>/dev/null

View File

@@ -0,0 +1,29 @@
#!/bin/sh
set -e
os=$(uname -s | tr "[:upper:]" "[:lower:]")
case $os in
linux)
platform="linux"
;;
darwin)
platform="macos"
;;
esac
filename="dartsdk-$platform-x64-release.zip"
curl -o "$filename" "https://storage.googleapis.com/dart-archive/channels/dev/release/latest/sdk/dartsdk-$platform-x64-release.zip"
unzip "$filename"
rm "$filename"
cat <<EOF >analysis-server-dart-snapshot
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)/dart-sdk
\$DIR/bin/dart language-server \$*
EOF
chmod +x analysis-server-dart-snapshot

View File

@@ -0,0 +1,15 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" tsserver typescript
"$(dirname "$0")/npm_install.sh" angular-language-server @angular/language-server
cat <<EOF >angular-language-server
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
node \$DIR/node_modules/@angular/language-server/index.js --ngProbeLocations \$DIR/node_modules/@angular/language-service --tsProbeLocations \$DIR/node_modules/typescript \$*
EOF
chmod +x angular-language-server

View File

@@ -0,0 +1,11 @@
#!/bin/sh
curl -o apex-jorje-lsp.jar -L "https://github.com/forcedotcom/salesforcedx-vscode/blob/develop/packages/salesforcedx-vscode-apex/out/apex-jorje-lsp.jar?raw=true"
cat <<EOF >apex-jorje-lsp
DIR=\$(cd \$(dirname \$0); pwd)
java -jar \$DIR/apex-jorje-lsp.jar %%* ^
EOF
chmod +x apex-jorje-lsp

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" astro-ls @astrojs/language-server

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" bash-language-server bash-language-server

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/go_install.sh" github.com/bufbuild/buf-language-server/cmd/bufls@latest

View File

@@ -0,0 +1,3 @@
#!/bin/sh
ros install cxxxr/lem cxxxr/cl-lsp

View File

@@ -0,0 +1,117 @@
#!/bin/sh
set -e
# On MacOS, use clangd in Command Line Tools for Xcode.
if command -v xcrun 2>/dev/null && xcrun --find clangd 2>/dev/null; then
cat <<'EOF' >clangd
#!/bin/sh
exec xcrun --run clangd "$@"
EOF
chmod +x clangd
exit
fi
if command -v lsb_release 2>/dev/null; then
distributor_id=$(lsb_release -a 2>&1 | grep 'Distributor ID' | awk '{print $3}')
elif [ -e /etc/fedora-release ]; then
distributor_id="Fedora"
elif [ -e /etc/redhat-release ]; then
distributor_id=$(cut -d ' ' -f 1 /etc/redhat-release)
elif [ -e /etc/arch-release ]; then
distributor_id="Arch"
elif [ -e /etc/SuSE-release ]; then
distributor_id="SUSE"
elif [ -e /etc/mandriva-release ]; then
distributor_id="Mandriva"
elif [ -e /etc/vine-release ]; then
distributor_id="Vine"
elif [ -e /etc/gentoo-release ]; then
distributor_id="Gentoo"
else
distributor_id="Unknown"
fi
filename() {
distributor_id=$1
version=$2
os=$(uname -s | tr "[:upper:]" "[:lower:]")
case $os in
linux)
platform="pc-linux-gnu"
;;
darwin)
platform="apple-darwin"
;;
esac
case $distributor_id in
# Check Ubuntu version
Ubuntu)
ubuntu_version=$(lsb_release -a 2>&1 | grep 'Release' | awk '{print $2}')
case $ubuntu_version in
14.04 | 16.04 | 18.04 | 20.04)
platform="linux-gnu-ubuntu-$ubuntu_version"
;;
22.04)
platform="linux-gnu-ubuntu-20.04"
;;
esac
;;
# Check LinuxMint version
LinuxMint)
linuxmint_version=$(lsb_release -a 2>&1 | grep 'Release' | awk '{print $2}')
case $linuxmint_version in
19 | 19.1 | 19.2 | 19.3)
platform="linux-gnu-ubuntu-18.04"
;;
18 | 18.1 | 18.2 | 18.3)
platform="linux-gnu-ubuntu-16.04"
;;
esac
;;
# Check RedHat OS version
Fedora | Oracle | CentOS)
case $version in
9.0.0 | 10.0.0)
platform="linux-sles11.3"
;;
11.0.0)
platform="linux-sles12.4"
;;
esac
;;
esac
# Check Architecture
arch=$(uname -m)
case $arch in
aarch64)
platform="linux-gnu"
;;
esac
echo "clang+llvm-$version-$arch-$platform"
}
# Search for an installable clang+llvm release.
for llvm_version in 15 14 13 12 11 10 9; do
filename="$(filename "$distributor_id" "$llvm_version.0.0")"
url="https://github.com/llvm/llvm-project/releases/download/llvmorg-$llvm_version.0.0/$filename.tar.xz"
response_code=$(curl -sIL "${url}" -o /dev/null -w "%{response_code}")
# If version exists, install it and exit.
if [ "${response_code}" -ne "404" ]; then
echo "Downloading clangd and LLVM $llvm_version..."
curl -L "$url" | unxz | tar x --strip-components=1 "$filename"/
ln -sf bin/clangd .
./clangd --version
exit 0
fi
done
echo "Could not find an installable clangd release!"
exit 1

View File

@@ -0,0 +1,3 @@
#!/bin/sh
VERSION="2020.05.09"
curl -L -o clj-kondo-lsp https://github.com/borkdude/clj-kondo/releases/download/v$VERSION/clj-kondo-lsp-server-$VERSION-standalone.jar

View File

@@ -0,0 +1,51 @@
#!/bin/sh
set -e
os="$(uname -s | tr "[:upper:]" "[:lower:]")"
arch="$(uname -m)"
case $os in
linux)
os_fixed="linux"
if [ "$arch" = "x86_64" ]; then
platform="amd64"
elif [ "$arch" = "aarch64" ] || [ "$arch" = "arm64" ]; then
platform="aarch64"
else
echo "unknown architecture: $arch"
exit 1
fi
;;
darwin)
os_fixed="macos"
if [ "$arch" = "x86_64" ]; then
platform="amd64"
elif [ "$arch" = "aarch64" ] || [ "$arch" = "arm64" ]; then
platform="aarch64"
else
echo "unknown architecture: $arch"
exit 1
fi
;;
mingw64_nt*)
os_fixed="windows"
if [ "$arch" = "x86_64" ]; then
platform="amd64"
else
echo "unknown architecture: $arch"
exit 1
fi
;;
*)
echo "unknow platform: $os"
exit 1
;;
esac
version="latest"
filename="clojure-lsp-native-${os_fixed}-${platform}.zip"
url="https://github.com/clojure-lsp/clojure-lsp/releases/${version}/download/${filename}"
curl -L -O ${url}
unzip ${filename}
chmod +x clojure-lsp

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/pip_install.sh" cmake-language-server cmake-language-server

View File

@@ -0,0 +1,18 @@
#!/bin/sh
set -e
version="0.9.1"
url="https://github.com/eclipse/che-che4z-lsp-for-cobol/releases/download/$version/cobol-language-support-$version.vsix"
filename="cobol-language-support-$version.vsix"
curl -L "$url" -o "$filename"
unzip "$filename"
rm "$filename"
cat <<EOF >./cobol-language-support
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
java "-Dline.speparator=\r\n" -jar "\$DIR/extension/server/lsp-service-cobol-$version.jar" pipeEnabled
EOF
chmod +x ./cobol-language-support

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" css-languageserver vscode-css-languageserver-bin

View File

@@ -0,0 +1,21 @@
#!/bin/sh
set -e
os=$(uname -s | tr "[:upper:]" "[:lower:]")
case $os in
linux)
filename="deno-x86_64-unknown-linux-gnu.zip"
;;
darwin)
if [ "$(uname -m)" = "x86_64" ]; then
filename="deno-x86_64-apple-darwin.zip"
else
filename="deno-aarch64-apple-darwin.zip"
fi
;;
esac
curl -L -o "deno-$os.zip" "https://github.com/denoland/deno/releases/latest/download/$filename"
unzip "deno-$os.zip"

View File

@@ -0,0 +1,21 @@
#!/bin/sh
set -e
os=$(uname -s | tr "[:upper:]" "[:lower:]")
case $os in
linux) ;;
darwin)
os="osx"
;;
*)
printf "%s doesn't supported by bash installer" "$os"
exit 1
;;
esac
version="v0.26.2"
url="https://github.com/d-language-server/dls/releases/download/$version/dls-$version.$os.x86_64.zip"
curl -LO "$url"
unzip "dls-$version.$os.x86_64.zip"

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" docker-langserver dockerfile-language-server-nodejs

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" dot-language-server dot-language-server

View File

@@ -0,0 +1,25 @@
#!/bin/sh
set -e
curl -o jdt-language-server-latest.tar.gz 'https://download.eclipse.org/jdtls/snapshots/jdt-language-server-latest.tar.gz'
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)"
echo "$osType"
case "$osType" in
Darwin*) configDir=config_mac ;;
Linux*) configDir=config_linux ;;
*) configDir=config_linux ;;
esac
cat <<EOF >eclipse-jdt-ls
#!/bin/sh
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/$configDir -data \$DIR/data
EOF
chmod +x eclipse-jdt-ls

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/go_install.sh" github.com/mattn/efm-langserver@latest

View File

@@ -0,0 +1,19 @@
#!/bin/sh
set -e
version="v0.12.0"
url="https://github.com/elixir-lsp/elixir-ls/releases/download/$version/elixir-ls.zip"
curl -LO "$url"
unzip elixir-ls.zip
rm elixir-ls.zip
cat <<EOF >elixir-ls
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
\$DIR/language_server.sh \$*
EOF
chmod +x language_server.sh
chmod +x elixir-ls

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" elm-language-server "@elm-tooling/elm-language-server"

View File

@@ -0,0 +1,15 @@
#!/bin/sh
set -e
version="0.3.6"
curl -L -o EmmyLua-LS-all.jar "https://github.com/EmmyLua/EmmyLua-LanguageServer/releases/download/$version/EmmyLua-LS-all.jar"
cat <<EOF >emmylua-ls
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
java -cp \$DIR/EmmyLua-LS-all.jar com.tang.vscode.MainKt
EOF
chmod +x emmylua-ls

View File

@@ -0,0 +1,8 @@
#!/bin/sh
set -e
git clone --depth=1 https://github.com/erlang-ls/erlang_ls .
make
ln -s ./_build/default/bin/erlang_ls erlang-ls

View File

@@ -0,0 +1,16 @@
#!/bin/sh
set -e
python3 -m venv ./venv
./venv/bin/pip3 install -U pip
./venv/bin/pip3 install "esbonio[lsp]"
cat <<EOF >esbonio
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
\$DIR/venv/bin/python3 -m esbonio
EOF
chmod +x esbonio

View File

@@ -0,0 +1,19 @@
#!/bin/sh
set -e
version="2.1.0"
url="https://github.com/microsoft/vscode-eslint/releases/download/release%2F$version-next.1/vscode-eslint-$version.vsix"
asset="vscode-eslint.vsix"
curl -L "$url" -o "$asset"
unzip "$asset"
rm "$asset"
cat <<EOF >eslint-language-server
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
node \$DIR/extension/server/out/eslintServer.js \$*
EOF
chmod +x eslint-language-server

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" flow flow-bin

View File

@@ -0,0 +1,3 @@
#!/bin/sh
"$(dirname "$0")/pip_install.sh" fortls fortran-language-server

View File

@@ -0,0 +1,15 @@
#!/bin/sh
set -e
if command -v dotnet >/dev/null 2>&1; then
echo "dotnet installed"
dotnetcmd=dotnet
else
echo "dotnet not found, installing..."
# REF https://github.com/neovim/nvim-lsp/blob/master/lua/nvim_lsp/pyls_ms.lua
curl -L https://dot.net/v1/dotnet-install.sh | bash -s -- -i "./.dotnet"
dotnetcmd="\\$DIR/.dotnet/dotnet"
fi
$dotnetcmd tool install --tool-path . fsautocomplete

View File

@@ -0,0 +1,18 @@
#!/bin/sh
set -e
git clone --depth=1 https://github.com/fsprojects/fsharp-language-server .
npm install
dotnet tool install --global paket
dotnet tool restore
dotnet publish src/FSharpLanguageServer --configuration Release --output Publish
cat <<EOF >fsharp-language-server
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
dotnet \$DIR/Publish/FSharpLanguageServer.dll \$*
EOF
chmod +x fsharp-language-server

View File

@@ -0,0 +1,6 @@
#!/bin/sh
set -e
"$(dirname "$0")/go_install.sh" github.com/nametake/golangci-lint-langserver@latest
"$(dirname "$0")/go_install.sh" github.com/golangci/golangci-lint/cmd/golangci-lint@latest

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/go_install.sh" golang.org/x/tools/gopls@latest

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" gql-language-server @playlyfe/gql-language-server

View File

@@ -0,0 +1,13 @@
#!/bin/sh
set -e
if [ ! -f package.json ]; then
# Avoid the problem of not being able to install the same package as name in package.json.
# Create an empty package.json.
npm init -y
echo '{"name": ""}' >package.json
fi
npm install "graphql-language-service-cli"
ln -s "./node_modules/.bin/graphql-lsp" graphql-language-server

View File

@@ -0,0 +1,15 @@
#!/bin/sh
set -e
git clone --depth=1 https://github.com/prominic/groovy-language-server .
./gradlew build
cat <<EOF >groovy-language-server
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
java -jar \$DIR/build/libs/groovy-language-server-all.jar \$*
EOF
chmod +x groovy-language-server

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" html-languageserver vscode-html-languageserver-bin

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" intelephense intelephense

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" javascript-typescript-stdio javascript-typescript-langserver

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/pip_install.sh" jedi-language-server jedi-language-server

View File

@@ -0,0 +1,6 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" vscode-json-languageserver vscode-json-languageserver
ln -s vscode-json-languageserver json-languageserver

View File

@@ -0,0 +1,13 @@
#!/bin/sh
set -e
julia -e 'using Pkg; Pkg.add("LanguageServer")'
cat <<EOF >julia-language-server
#!/bin/sh
julia -e "using LanguageServer, LanguageServer.SymbolServer; runserver()"
EOF
chmod +x julia-language-server

View File

@@ -0,0 +1,10 @@
#!/bin/sh
set -e
version="0.5.2"
curl -L -o server.zip "https://github.com/fwcd/kotlin-language-server/releases/download/$version/server.zip"
unzip server.zip
rm server.zip
ln -s server/bin/kotlin-language-server .

View File

@@ -0,0 +1,18 @@
#!/bin/sh
set -e
version="0.14.1"
url="https://repo.eclipse.org/content/repositories/lemminx-releases/org/eclipse/lemminx/org.eclipse.lemminx/${version}/org.eclipse.lemminx-${version}-uber.jar"
lemminx_jar="org.eclipse.lemminx-${version}-uber.jar"
curl -L "$url" -o "${lemminx_jar}"
cat <<EOF >lemminx
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
java -jar \$DIR/${lemminx_jar}
EOF
chmod +x lemminx

View File

@@ -0,0 +1,17 @@
#!/bin/sh
set -e
os=$(uname -s | tr "[:upper:]" "[:lower:]")
case $os in
linux)
platform="linux"
;;
darwin)
platform="macos"
;;
esac
curl -L -o marksman "https://github.com/artempyanykh/marksman/releases/latest/download/marksman-$platform"
chmod +x marksman

View File

@@ -0,0 +1,36 @@
#!/bin/sh
set -e
curl -Lo ./coursier https://git.io/coursier-cli
chmod +x ./coursier
version=$(curl -LsS "https://scalameta.org/metals/latests.json" | grep -o '"release": "[^"]*"' | grep -o '[\.0-9]*')
java_flags=
if [ -n "${https_proxy}" ]; then
https_proxy_without_protocol="${https_proxy#http://}"
java_flags="$java_flags -J-Dhttps.proxyHost=${https_proxy_without_protocol%:*}"
java_flags="$java_flags -J-Dhttps.proxyPort=${https_proxy_without_protocol##*:}"
fi
if [ -n "${http_proxy}" ]; then
http_proxy_without_protocol="${http_proxy#http://}"
java_flags="$java_flags -J-Dhttp.proxyHost=${http_proxy_without_protocol%:*}"
java_flags="$java_flags -J-Dhttp.proxyPort=${http_proxy_without_protocol##*:}"
fi
if [ -n "${no_proxy}" ]; then
java_flags="$java_flags -J-Dhttp.nonProxyHosts=${no_proxy}"
fi
# shellcheck disable=SC2086
./coursier bootstrap \
--java-opt -Xss4m \
--java-opt -Xms100m \
${java_flags} \
org.scalameta:metals_2.13:"${version}" \
-r bintray:scalacenter/releases \
-r sonatype:releases \
-o metals -f

View File

@@ -0,0 +1,6 @@
#!/bin/sh
set -e
nimble -y --nimbledir="$(pwd)" install nimlsp
ln -s "$(pwd)/bin/nimlsp" .

View File

@@ -0,0 +1,20 @@
#!/bin/sh
set -e
#set -o pipefail
os="$(uname -s | tr "[:upper:]" "[:lower:]")"
case "${os}" in
darwin | linux)
url="https://github.com/nokia/ntt/releases/latest/download/ntt_${os}_x86_64.tar.gz"
curl -L "$url" | tar xz ntt
chmod +x ntt
;;
*)
echo >&2 "$os is not supported"
exit 1
;;
esac

View File

@@ -0,0 +1,26 @@
#!/bin/sh
set -e
DEFAULT_DIR="$(pwd)"
# We should not download GitHub's zip file here, because it doesn't include some submodules.
git clone --recurse-submodules http://github.com/ocaml/ocaml-lsp.git ocaml-lsp-files --depth=1
cd ocaml-lsp-files
rm -r lsp/test
OPAMROOT="$(pwd)/.opam"
export OPAMROOT
export OPAMYES=true
opam init -a -n
opam switch create . ocaml-base-compiler.4.14.0
eval "$(opam env)" 2>/dev/null
opam exec make install-test-deps
opam exec make all
rm -rf .git
cd "$DEFAULT_DIR"
ln -snf "./ocaml-lsp-files/_build/default/ocaml-lsp-server/bin/main.exe" ocaml-lsp
chmod +x ocaml-lsp

View File

@@ -0,0 +1,6 @@
#!/bin/sh
set -e
git clone --depth=1 https://github.com/DanielGavin/ols_
cd ols_ && ./build.sh && cp ols .. && cd .. && rm -rf ols_

View File

@@ -0,0 +1,64 @@
#!/bin/sh
set -e
os=$(uname -s | tr "[:upper:]" "[:lower:]")
arch="-x64"
net6=""
version=$(dotnet --version)
case $os in
linux) ;;
darwin)
os="osx"
arch=""
;;
*)
printf "%s doesn't supported by bash installer" "$os"
exit 1
;;
esac
case $version in
*.*)
mainVersion=${version%%.*}
;;
*)
mainVersion=$version
;;
esac
if [ "$mainVersion" -ge "6" ]; then
net6="-net6.0"
if [ "$os" = "osx" ]; then
if [ "$(uname -m)" = "x86_64" ]; then
arch="-x64"
else
arch="-$(uname -m)"
fi
fi
cat <<EOF >run
#!/bin/sh
base_dir="\$(cd "\$(dirname "\$0")" && pwd -P)"
omnisharp_cmd=\${base_dir}/OmniSharp
"\${omnisharp_cmd}" "\$@"
EOF
fi
url="https://github.com/OmniSharp/omnisharp-roslyn/releases/latest/download/omnisharp-$os$arch$net6.tar.gz"
curl -L "$url" | tar xz
chmod +x run
cat <<EOF >omnisharp-lsp
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
\$DIR/run \$*
EOF
chmod +x omnisharp-lsp

View File

@@ -0,0 +1,21 @@
#!/bin/sh
set -e
os=$(uname -s | tr "[:upper:]" "[:lower:]")
case $os in
linux) ;;
darwin)
os="macos"
;;
*)
printf "%s doesn't supported by bash installer" "$os"
exit 1
;;
esac
curl -L -o "perlnavigator-$os-x86_64.zip" "https://github.com/bscan/PerlNavigator/releases/latest/download/perlnavigator-$os-x86_64.zip"
unzip "perlnavigator-$os-x86_64.zip"
mv "perlnavigator-$os-x86_64/perlnavigator" .
rm -rf "perlnavigator-$os-x86_64" "perlnavigator-$os-x86_64.zip"

View File

@@ -0,0 +1,16 @@
#!/bin/sh
set -e
git clone --depth=1 https://github.com/UniqueVision/plpgsql-lsp .
npm install
npm run build
cat <<EOF >plpgsql-lsp
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
node \$DIR/server/out/server.js \$*
EOF
chmod +x plpgsql-lsp

View File

@@ -0,0 +1,19 @@
#!/bin/sh
set -e
curl -L -o PowerShellEditorServices.zip "https://github.com/PowerShell/PowerShellEditorServices/releases/download/v2.1.0/PowerShellEditorServices.zip"
unzip PowerShellEditorServices.zip
rm PowerShellEditorServices.zip
mkdir session
cat <<EOF >powershell-languageserver
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
PSES_BUNDLE_PATH=\$DIR/PowerShellEditorServices
SESSION_TEMP_PATH=\$DIR/session
pwsh -NoLogo -NoProfile -ExecutionPolicy RemoteSigned -Command "\$PSES_BUNDLE_PATH/PowerShellEditorServices/Start-EditorServices.ps1 -BundledModulesPath \$PSES_BUNDLE_PATH -LogPath \$SESSION_TEMP_PATH/logs.log -SessionDetailsPath \$SESSION_TEMP_PATH/session.json -FeatureFlags @() -AdditionalModules @() -HostName 'My Client' -HostProfileId 'myclient' -HostVersion 1.0.0 -Stdio -LogLevel Normal"
EOF
chmod +x powershell-languageserver

View File

@@ -0,0 +1,20 @@
#!/bin/sh
set -e
if [ ! -f package.json ]; then
# Avoid the problem of not being able to install the same package as name in package.json.
# Create an empty package.json.
npm init -y
echo '{"name": ""}' >package.json
fi
npm install "@prisma/engines"
_DIR="$PWD"
cd "node_modules/@prisma/engines"
PRISMA_FMT_BASENAME="$(find . -name "prisma-fmt*")"
test -x "$PRISMA_FMT_BASENAME"
cd "$_DIR"
ln -s "./node_modules/@prisma/engines/${PRISMA_FMT_BASENAME}" ./prisma-fmt
"$(dirname "$0")/npm_install.sh" prisma-language-server @prisma/language-server

View File

@@ -0,0 +1,6 @@
#!/bin/sh
set -e
composer require vimeo/psalm
ln -s "./vendor/bin/psalm-language-server" .

View File

@@ -0,0 +1,16 @@
#!/bin/sh
set -o errexit
git clone --depth=1 https://github.com/puppetlabs/puppet-editor-services.git .
bundle config set --local path 'vendor/bundle'
bundle install
bundle exec rake gem_revendor
cat <<'EOF' >puppet-ls
#!/bin/sh
set -o errexit
cd "$(dirname "$0")"
exec bundle exec ruby ./puppet-languageserver "$@"
EOF
chmod +x puppet-ls

View File

@@ -0,0 +1,5 @@
#!/usr/bin/env bash
set -e
"$(dirname "$0")/npm_install.sh" purescript-language-server "purescript-language-server"

View File

@@ -0,0 +1,6 @@
#!/bin/sh
set -e
"$(dirname "$0")/pip_install.sh" pyls 'python-language-server[all]'
mv pyls pyls-all

View File

@@ -0,0 +1,34 @@
#!/bin/sh
set -e
# REF https://github.com/neovim/nvim-lsp/blob/master/lua/nvim_lsp/pyls_ms.lua
curl -L https://dot.net/v1/dotnet-install.sh | bash -s -- -i "./.dotnet"
os=$(uname -s | tr "[:upper:]" "[:lower:]")
case $os in
linux)
system="linux"
;;
darwin)
system="osx"
;;
*) ;;
esac
version="0.5.59"
url="https://pvsc.azureedge.net/python-language-server-stable/Python-Language-Server-${system}-x64.${version}.nupkg"
nupkg="./pyls.nupkg"
curl -L "$url" -o "$nupkg"
unzip "$nupkg"
cat <<EOF >pyls-ms
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
\$DIR/.dotnet/dotnet \$DIR/Microsoft.Python.LanguageServer.dll
EOF
chmod +x pyls-ms

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/pip_install.sh" pyls python-language-server

View File

@@ -0,0 +1,6 @@
#!/bin/sh
set -e
"$(dirname "$0")/pip_install.sh" pylsp 'python-lsp-server[all]'
mv pylsp pylsp-all

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/pip_install.sh" pylsp python-lsp-server

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" pyright-langserver pyright

View File

@@ -0,0 +1,14 @@
#!/bin/sh
set -e
echo 'install.packages("languageserver", repos = "https://cran.r-project.org")' >install.r
Rscript install.r
cat <<EOF >r-languageserver
#!/bin/sh
R --slave -e 'languageserver::run()'
EOF
chmod +x r-languageserver

View File

@@ -0,0 +1,10 @@
#!/bin/sh
raco pkg install racket-langserver
cat <<EOF >racket-lsp
#!/bin/sh
racket -l racket-langserver
EOF
chmod +x racket-lsp

View File

@@ -0,0 +1,23 @@
#!/bin/sh
set -e
os=$(uname -s | tr "[:upper:]" "[:lower:]")
case $os in
linux) ;;
darwin)
os="macos"
;;
*)
printf "%s doesn't supported by bash installer" "$os"
exit 1
;;
esac
version="1.7.5"
url="https://github.com/jaredly/reason-language-server/releases/download/$version/rls-$os.zip"
curl -LO "$url"
unzip "rls-$os.zip"
ln -s "./rls-$os/reason-language-server" .

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" remark-language-server remark-language-server

View File

@@ -0,0 +1,5 @@
#!/usr/bin/env bash
set -e
nix-env -i -f "https://github.com/nix-community/rnix-lsp/archive/master.tar.gz"

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" rome rome

View File

@@ -0,0 +1,17 @@
#!/bin/sh
set -e
git clone --depth=1 https://github.com/Shopify/ruby-lsp .
bundle config set --local path vendor/bundle
bundle config set --local without development
bundle install
cat <<EOF >ruby-lsp
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
BUNDLE_GEMFILE=\$DIR/Gemfile bundle exec ruby \$DIR/exe/ruby-lsp \$*
EOF
chmod +x ruby-lsp

View File

@@ -0,0 +1,17 @@
#!/bin/sh
set -e
git clone --depth=1 https://github.com/kwerle/ruby_language_server .
bundle config set --local path vendor/bundle
bundle config set --local without development
bundle install
cat <<EOF >ruby_language_server
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
BUNDLE_GEMFILE=\$DIR/Gemfile bundle exec ruby \$DIR/exe/ruby_language_server \$*
EOF
chmod +x ruby_language_server

View File

@@ -0,0 +1,49 @@
#!/bin/sh
set -e
os=$(uname -s | tr "[:upper:]" "[:lower:]")
arch="$(uname -m)"
case $os in
linux)
if [ "$arch" = "x86_64" ]; then
platform="x86_64-unknown-linux-gnu"
elif [ "$arch" = "aarch64" ]; then
platform="aarch64-unknown-linux-gnu"
else
echo "unknown architecture: $arch"
exit 1
fi
;;
darwin)
if [ "$arch" = "x86_64" ]; then
platform="x86_64-apple-darwin"
elif [ "$arch" = "aarch64" ] || [ "$arch" = "arm64" ]; then
platform="aarch64-apple-darwin"
else
echo "unknown architecture: $arch"
exit 1
fi
;;
mingw64_nt*)
if [ "$arch" = "x86_64" ]; then
platform="x86_64-pc-windows-msvc"
elif [ "$arch" = "aarch64" ] || [ "$arch" = "arm64" ]; then
platform="aarch64-pc-windows-msvc"
else
echo "unknown architecture: $arch"
exit 1
fi
;;
*)
echo "unknow platform: $os"
exit 1
;;
esac
curl -L -o "rust-analyzer-$platform.gz" "https://github.com/rust-analyzer/rust-analyzer/releases/latest/download/rust-analyzer-$platform.gz"
gzip -d "rust-analyzer-$platform.gz"
mv rust-analyzer-$platform rust-analyzer
chmod +x rust-analyzer

View File

@@ -0,0 +1,21 @@
#!/bin/sh
set -e
os=$(uname -s | tr "[:upper:]" "[:lower:]")
case $os in
linux) ;;
darwin)
os="osx"
;;
*)
echo "$os is not supported by installer"
exit 1
;;
esac
version="0.6.0"
filename="serve-d_$version-$os-x86_64.tar.xz"
url="https://github.com/Pure-D/serve-d/releases/download/v$version/$filename"
curl -L "$url" | unxz | tar x

View File

@@ -0,0 +1,17 @@
#!/bin/sh
set -e
git clone --depth=1 https://github.com/castwide/solargraph .
bundle config set --local path vendor/bundle
bundle config set --local without development
bundle install
cat <<EOF >solargraph
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
BUNDLE_GEMFILE=\$DIR/Gemfile bundle exec ruby \$DIR/bin/solargraph \$*
EOF
chmod +x solargraph

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" sql-language-server sql-language-server

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/go_install.sh" github.com/lighttiger2505/sqls@latest

View File

@@ -0,0 +1,17 @@
#!/bin/sh
set -e
git clone --depth=1 https://github.com/soutaro/steep.git .
bundle config set --local path vendor/bundle
bundle config set --local without development
bundle install
cat <<EOF >steep
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
BUNDLE_GEMFILE=\$DIR/Gemfile bundle exec steep \$*
EOF
chmod +x steep

View File

@@ -0,0 +1,60 @@
#!/bin/sh
set -e
os="$(uname -s | tr "[:upper:]" "[:lower:]")"
arch="$(uname -m)"
case $os in
linux)
if [ "$arch" = "x86_64" ]; then
platform="linux-x64"
elif [ "$arch" = "aarch64" ] || [ "$arch" = "arm64" ]; then
platform="linux-arm64"
else
echo "unknown architecture: $arch"
exit 1
fi
;;
darwin)
if [ "$arch" = "x86_64" ]; then
platform="darwin-x64"
elif [ "$arch" = "aarch64" ] || [ "$arch" = "arm64" ]; then
platform="darwin-arm64"
else
echo "unknown architecture: $arch"
exit 1
fi
;;
mingw64_nt*)
if [ "$arch" = "x86_64" ]; then
platform="win32-x64"
else
echo "unknown architecture: $arch"
exit 1
fi
;;
*)
echo "unknow platform: $os"
exit 1
;;
esac
version="v3.0.0"
url="https://github.com/sumneko/vscode-lua/releases/download/$version/vscode-lua-$version-$platform.vsix"
asset="vscode-lua.vsix"
curl -L "$url" -o "$asset"
unzip "$asset"
rm "$asset"
chmod +x extension/server/bin/lua-language-server
cat <<EOF >sumneko-lua-language-server
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)/extension/server
\$DIR/bin/lua-language-server -E -e LANG=en \$DIR/main.lua \$*
EOF
chmod +x sumneko-lua-language-server

View File

@@ -0,0 +1,6 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" svelteserver svelte-language-server
mv svelteserver svelte-language-server

View File

@@ -0,0 +1,23 @@
#!/bin/sh
set -e
os=$(uname -s | tr "[:upper:]" "[:lower:]")
case $os in
linux)
os="lnx"
;;
darwin)
os="mac"
;;
*)
printf "%s doesn't supported by bash installer" "$os"
exit 1
;;
esac
version="v0.1.16"
curl -L -o svls-$version-x86_64-$os.zip "https://github.com/dalance/svls/releases/download/$version/svls-$version-x86_64-$os.zip"
unzip svls-$version-x86_64-$os.zip
rm svls-$version-x86_64-$os.zip

View File

@@ -0,0 +1,22 @@
#!/bin/sh
set -e
version="0.5.10"
url="https://github.com/tailwindlabs/tailwindcss-intellisense/releases/download/v$version/vscode-tailwindcss-$version.vsix"
asset="vscode-tailwindcss.vsix"
curl -L "$url" -o "$asset"
unzip "$asset"
rm "$asset" \[Content_Types\].xml extension.vsixmanifest
chmod +x extension/dist/server/index.js
cat <<EOF >tailwindcss-intellisense
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
node \$DIR/extension/dist/server/index.js \$*
EOF
chmod +x tailwindcss-intellisense

View File

@@ -0,0 +1,18 @@
#!/bin/sh
set -e
os=$(uname -s | tr "[:upper:]" "[:lower:]")
case $os in
linux)
platform="linux-"$(uname -m)
;;
darwin)
platform="darwin-"$(uname -m)
;;
esac
curl -L "https://github.com/tamasfe/taplo/releases/latest/download/taplo-full-$platform.gz" | gzip -d >taplo-lsp
chmod +x taplo-lsp

View File

@@ -0,0 +1,37 @@
#!/bin/sh
set -e
os=$(uname -s | tr "[:upper:]" "[:lower:]")
arch=$(uname -m | tr "[:upper:]" "[:lower:]")
case $os in
darwin | linux) ;;
*)
printf "%s is not supported" "$os"
exit 1
;;
esac
case $arch in
x86_64*) arch=amd64 ;;
386*) arch=386 ;;
arm64*) arch=arm64 ;;
aarch64*) arch=arm64 ;;
*)
printf "%s is not supported" "$arch"
exit 1
;;
esac
version=$(basename "$(curl -Ls -o /dev/null -w %\{url_effective\} https://github.com/hashicorp/terraform-ls/releases/latest)")
short_version=$(echo "$version" | cut -c2-)
filename="terraform-ls_${short_version}"
url="https://github.com/hashicorp/terraform-ls/releases/download/${version}/${filename}_${os}_${arch}.zip"
filename="${filename}.zip"
curl -L --progress-bar "$url" -o "$filename"
unzip "$filename"
rm "$filename"

View File

@@ -0,0 +1,18 @@
#!/bin/sh
set -e
os=$(uname -s | tr "[:upper:]" "[:lower:]")
version="0.0.12"
case $os in
darwin | linux)
url="https://github.com/juliosueiras/terraform-lsp/releases/download/v${version}/terraform-lsp_${version}_${os}_amd64.tar.gz"
curl -L "$url" | tar zx
;;
*)
printf "%s doesn't supported" "$os"
exit 1
;;
esac

View File

@@ -0,0 +1,35 @@
#!/bin/sh
set -e
os=$(uname -s | tr "[:upper:]" "[:lower:]")
arch=$(uname -m)
case $os in
linux) ;;
darwin)
os="macos"
;;
*)
printf "%s doesn't supported by bash installer" "$os"
exit 1
;;
esac
case $arch in
x86_64) ;;
arm64)
if [ "$os" = "linux" ]; then
printf "%s doesn't supported by bash installer" "$os"
exit 1
fi
arch="aarch64"
;;
*)
printf "%s doesn't supported by bash installer" "$os"
exit 1
;;
esac
url="https://github.com/latex-lsp/texlab/releases/latest/download/texlab-$arch-$os.tar.gz"
curl -L "$url" | tar xzv

View File

@@ -0,0 +1,17 @@
#!/bin/sh
set -e
git clone --depth=1 -b lsp-test https://github.com/ruby/typeprof .
bundle config set --local path vendor/bundle
bundle config set --local without development
bundle install
cat <<EOF >typeprof
#!/bin/sh
DIR=\$(cd \$(dirname \$0); pwd)
BUNDLE_GEMFILE=\$DIR/Gemfile bundle exec ruby \$DIR/exe/typeprof \$*
EOF
chmod +x typeprof

View File

@@ -0,0 +1,6 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" tsserver typescript
"$(dirname "$0")/npm_install.sh" typescript-language-server typescript-language-server

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" vim-language-server vim-language-server

View File

@@ -0,0 +1,7 @@
#!/bin/sh
git clone --depth=1 https://github.com/vlang/vls .
echo 'Compiling vlang/vls...'
v -prod cmd/vls
mv cmd/vls/vls vlang-vls
rm -rf instructions.png cmd jsonrpc lsp vls tests

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" vls vls

View File

@@ -0,0 +1,7 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" vue-language-server @volar/vue-language-server@~1.0.0
mv vue-language-server volar-server
npm install typescript@4.8

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" vscode-css-language-server vscode-langservers-extracted

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" vscode-html-language-server vscode-langservers-extracted

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" vscode-json-language-server vscode-langservers-extracted

View File

@@ -0,0 +1,5 @@
#!/bin/sh
set -e
"$(dirname "$0")/npm_install.sh" yaml-language-server yaml-language-server

View File

@@ -0,0 +1,11 @@
#!/bin/sh
git clone https://github.com/zigtools/zls .
git checkout "refs/tags/$(git tag | grep "^$(zig version | sed -r 's/\.[0-9]+$//')")"
git submodule update --init --recursive
zig build
mv zig-out/bin/zls .
rm -rf zig-cache zig-out src tests
cat <<EOF >zls.json
{"zig_lib_path":"$(dirname "$(which zig)")/lib/zig","enable_snippets":true,"warn_style":true,"enable_semantic_tokens":true}
EOF

View File

@@ -0,0 +1,18 @@
#!/bin/sh
# Usage
# $ npm_install [EXECUTABLE_NAME] [NPM_NAME]
set -e
# Supporting multiple npm packages(e.g. typescript-language-server uses typescript-language-server and tsserver).
# If package.json exists, skip calling npm init.
if [ ! -f package.json ]; then
# Avoid the problem of not being able to install the same package as name in package.json.
# Create an empty package.json.
npm init -y
echo '{"name": ""}' >package.json
fi
npm install "$2"
ln -s "./node_modules/.bin/$1" .

View File

@@ -0,0 +1,11 @@
#!/bin/sh
# Usage
# $ pip_install [EXECUTABLE_NAME] [PYPI_NAME]
set -e
python3 -m venv ./venv
./venv/bin/pip3 install -U pip
./venv/bin/pip3 install "$2"
ln -s "./venv/bin/$1" .

View File

@@ -0,0 +1,18 @@
#!/bin/sh
# Usage
# $ yarn_install [EXECUTABLE_NAME] [NPM_NAME]
set -e
# Supporting multiple yarn packages(e.g. typescript-language-server uses typescript-language-server and tsserver).
# If package.json exists, skip calling yarn init.
if [ ! -f package.json ]; then
# Avoid the problem of not being able to install the same package as name in package.json.
# Create an empty package.json.
yarn init -y
echo '{"name": ""}' >package.json
fi
yarn add "$2"
ln -s "./node_modules/.bin/$1" .

View File

@@ -0,0 +1,13 @@
@echo off
if "x%1" equ "x" goto :EOF
setlocal
set GO111MODULE=on
set GOPATH=%cd%
set GOBIN=%cd%
go install -v %1
set GOBIN=
go clean -modcache
rd /S /Q "src" "pkg" 2> NUL

Some files were not shown because too many files have changed in this diff Show More