This commit is contained in:
pika 2024-10-27 22:35:27 +00:00 committed by GitHub
commit 5c40bc73b4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -15,25 +15,25 @@ cloneNeovim() {
installNeovim() {
if ! command_exists neovim ripgrep git fzf; then
printf "%b\n" "${YELLOW}Installing Neovim...${RC}"
case "$PACKAGER" in
printf "%b\n" "${YELLOW}Installing Neovim...${RC}"
case "$PACKAGER" in
pacman)
"$ESCALATION_TOOL" "$PACKAGER" -S --needed --noconfirm neovim ripgrep fzf python-virtualenv luarocks go shellcheck git
;;
apt-get|nala)
apt-get | nala)
"$ESCALATION_TOOL" "$PACKAGER" install -y ripgrep fd-find python3-venv luarocks golang-go shellcheck git
curl -sSLo /tmp/nvim.appimage https://github.com/neovim/neovim/releases/latest/download/nvim.appimage
chmod u+x /tmp/nvim.appimage
"$ESCALATION_TOOL" mv /tmp/nvim.appimage /usr/local/bin/nvim
;;
dnf|zypper)
dnf | zypper)
"$ESCALATION_TOOL" "$PACKAGER" install -y neovim ripgrep fzf python3-virtualenv luarocks golang ShellCheck git
;;
*)
printf "%b\n" "${RED}Unsupported package manager: ""$PACKAGER""${RC}"
exit 1
;;
esac
esac
fi
}
@ -51,9 +51,22 @@ linkNeovimConfig() {
ln -s "$gitpath/titus-kickstart/"* "$HOME/.config/nvim/" # Wild card is used here to link all contents of titus-kickstart.
}
dotsPrompt() {
printf "%b\n" "${GREEN}Do you want to install Titus' Neovim? (Y/n): ${RC}"
read -r _titusDots
case "$_titusDots" in
N | n)
printf "%b\n" "${YELLOW}Installation complete.."
;;
*)
cloneNeovim
backupNeovimConfig
linkNeovimConfig
;;
esac
}
checkEnv
checkEscalationTool
installNeovim
cloneNeovim
backupNeovimConfig
linkNeovimConfig
dotsPrompt