-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathci-install.sh
26 lines (24 loc) · 1.08 KB
/
ci-install.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/bin/bash
set -e
os=$(uname -s)
if [[ $os == Linux ]]; then
wget https://github.com/neovim/neovim/releases/download/${NVIM_TAG}/nvim-linux64.tar.gz
tar -zxf nvim-linux64.tar.gz
sudo ln -s "$PWD"/nvim-linux64/bin/nvim /usr/local/bin
rm -rf "$PWD"/nvim-linux64/lib/nvim/parser
mkdir -p ~/.local/share/nvim/site/pack/nvim-treesitter/start
ln -s "$PWD" ~/.local/share/nvim/site/pack/nvim-treesitter/start
elif [[ $os == Darwin ]]; then
RELEASE_NAME="nvim-macos-$(uname -m)"
curl -L "https://github.com/neovim/neovim/releases/download/${NVIM_TAG}/$RELEASE_NAME.tar.gz" | tar -xz
sudo ln -s "$PWD/$RELEASE_NAME/bin/nvim" /usr/local/bin
rm -rf "$PWD/$RELEASE_NAME/lib/nvim/parser"
mkdir -p ~/.local/share/nvim/site/pack/nvim-treesitter/start
ln -s "$PWD" ~/.local/share/nvim/site/pack/nvim-treesitter/start
else
curl -L https://github.com/neovim/neovim/releases/download/${NVIM_TAG}/nvim-win64.zip -o nvim-win64.zip
unzip nvim-win64
mkdir -p ~/AppData/Local/nvim/pack/nvim-treesitter/start
mkdir -p ~/AppData/Local/nvim-data
cp -r "$PWD" ~/AppData/Local/nvim/pack/nvim-treesitter/start
fi