mirror of
https://github.com/ViViDboarder/vim-settings.git
synced 2025-02-09 05:07:28 +00:00
Update language server install to fix pip and add rustfmt
This commit is contained in:
parent
acf484c4bd
commit
0ac1019486
@ -1,6 +1,9 @@
|
||||
#! /bin/bash
|
||||
set -e
|
||||
|
||||
# Clear explicit PYTHONPATH since this gets confused between py2 and py3
|
||||
export PYTHONPATH=""
|
||||
|
||||
# Determines if a command exists or not
|
||||
function command_exist() {
|
||||
command -v "$1" > /dev/null 2>&1;
|
||||
@ -10,6 +13,7 @@ function command_exist() {
|
||||
function maybe_run() {
|
||||
if command_exist "$1" ;then
|
||||
echo "> $*"
|
||||
# shellcheck disable=2048,2086
|
||||
eval $*
|
||||
else
|
||||
echo "ERROR: $1 does not exist. Could not run $*"
|
||||
@ -31,7 +35,7 @@ function install_language_servers() {
|
||||
maybe_run pip3 install --user python-language-server
|
||||
|
||||
# Rust
|
||||
maybe_run rustup component add rls rust-analysis rust-src
|
||||
maybe_run rustup component add rls rustfmt rust-analysis rust-src
|
||||
|
||||
echo ""
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user