-
Notifications
You must be signed in to change notification settings - Fork 1
/
setup.sh
executable file
·34 lines (27 loc) · 976 Bytes
/
setup.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
27
28
29
30
31
32
33
#!/bin/bash
# Node is required for Copilot.
if [[ "$OSTYPE" == "darwin"* ]]; then
brew list -q node || brew install node
elif [[ "$OSTYPE" == "linux-gnu"* ]]; then
sudo apt install -y nodejs
fi
# Neovim
if ! command -v nvim &> /dev/null; then
curl -LO https://github.com/neovim/neovim/releases/latest/download/nvim.appimage
chmod u+x nvim.appimage
./nvim.appimage --appimage-extract
./squashfs-root/AppRun --version
sudo mv squashfs-root /
sudo ln -s /squashfs-root/AppRun /usr/bin/nvim
fi
# packer
if [ ! -d ~/.local/share/nvim/site/pack/packer/start/packer.nvim ]; then
git clone --depth 1 https://github.com/wbthomason/packer.nvim \
~/.local/share/nvim/site/pack/packer/start/packer.nvim 2> /dev/null
fi
# Copilot
if [ ! -d ~/.config/nvim/pack/github/start/copilot.vim ]; then
git clone https://github.com/github/copilot.vim.git \
~/.config/nvim/pack/github/start/copilot.vim 2> /dev/null
fi
npm i -g pyright