From 9666bfb7159880d937ec6bb7729e7736e76bd58a Mon Sep 17 00:00:00 2001 From: Harivansh Rathi Date: Wed, 21 Jan 2026 16:59:34 -0500 Subject: [PATCH] installation wiz --- README.md | 19 +++++++++++++++++++ init.lua | 3 --- install.sh | 28 ++++++++++++++++++++++++---- 3 files changed, 43 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 365b3e9..0bec656 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,24 @@ # nvim +## Installation + +**Minimal (default)** - lightweight, no LSP, no AI completion: +```bash +curl -fsSL https://raw.githubusercontent.com/harivansh-afk/nvim/main/install.sh | bash +``` + +**Full install** - includes LSP + supermaven AI completion: +```bash +curl -fsSL https://raw.githubusercontent.com/harivansh-afk/nvim/main/install.sh | bash -s -- --bells-and-whistles +``` + +Other options: +```bash +--skip-nvim # Config only (skip nvim install) +--skip-config # Nvim only (skip config install) +--no-path # Don't modify shell rc files +``` + ## Repo tree ```text diff --git a/init.lua b/init.lua index 5eb2777..887c13e 100644 --- a/init.lua +++ b/init.lua @@ -51,9 +51,6 @@ vim.opt.ruler = false -- Disable native ruler (NvChad statusline shows position vim.opt.cmdheight = 0 -- Hide command line when not in use vim.opt.laststatus = 3 -- Global statusline at the very bottom --- Enable cursor blinking -vim.opt.guicursor = "n-v-c:block-blinkwait700-blinkoff400-blinkon250,i-ci-ve:ver25-blinkwait700-blinkoff400-blinkon250,r-cr:hor20-blinkwait700-blinkoff400-blinkon250" - -- Keymaps vim.keymap.set("n", "q", ":q", { desc = "Quit" }) diff --git a/install.sh b/install.sh index 8d96d0d..4dd7955 100755 --- a/install.sh +++ b/install.sh @@ -22,6 +22,7 @@ REPO_URL="https://github.com/harivansh-afk/nvim.git" SKIP_NVIM=0 SKIP_CONFIG=0 NO_PATH=0 +FULL_INSTALL=0 while [[ $# -gt 0 ]]; do case "$1" in @@ -33,15 +34,17 @@ while [[ $# -gt 0 ]]; do --skip-nvim) SKIP_NVIM=1; shift ;; --skip-config) SKIP_CONFIG=1; shift ;; --no-path) NO_PATH=1; shift ;; + --bells-and-whistles) FULL_INSTALL=1; shift ;; -h|--help) cat <<'EOF' Usage: install.sh [options] Options: - --repo URL Clone config from URL (default: repo in this script) - --skip-nvim Do not install Neovim - --skip-config Do not install config - --no-path Do not modify shell rc files + --repo URL Clone config from URL (default: repo in this script) + --skip-nvim Do not install Neovim + --skip-config Do not install config + --no-path Do not modify shell rc files + --bells-and-whistles Full install with LSP and AI completion (default: minimal) EOF exit 0 ;; @@ -224,6 +227,20 @@ install_config() { mkdir -p "${CONFIG_DIR}/undodir" } +strip_heavy_plugins() { + local plugins_dir="${CONFIG_DIR}/lua/plugins" + local heavy_plugins=( + "supermaven.lua" + "lsp.lua" + ) + for plugin in "${heavy_plugins[@]}"; do + if [[ -f "${plugins_dir}/${plugin}" ]]; then + rm "${plugins_dir}/${plugin}" + log "Removed ${plugin} (minimal install)" + fi + done +} + log "Installing nvim config from ${REPO_URL} (${OS}/${ARCH})" ensure_local_bin_path @@ -233,6 +250,9 @@ fi if [[ "$SKIP_CONFIG" -eq 0 ]]; then install_config + if [[ "$FULL_INSTALL" -eq 0 ]]; then + strip_heavy_plugins + fi fi if have nvim; then