view vim-setup/start.sh @ 279:b3b547563ec7

Add Google connector service and agent wiki Implement the C/Seobeo Google Drive and Gmail connector with encrypted OAuth storage, Zenbu authentication, browser testing, AI tool discovery, chunked HTTP decoding, and Bazel coverage. Consolidate repository guidance into progressive wiki documentation and enforce arena-first allocation for new first-party C code. Co-authored-by: Copilot <[email protected]> Copilot-Session: 84c338fd-0939-4bb3-b7f3-1062eb213e5d
author MrJuneJune <me@mrjunejune.com>
date Mon, 17 Aug 2026 22:22:36 -0700
parents 76cd7afa6b8e
children
line wrap: on
line source

#!/bin/bash

set -e

# Not using plugin management since it is cancer
PLUG_DIR="$HOME/.vim/pack/plugins/start"
THEME_DIR="$HOME/.vim/pack/themes/start"
NEOVIM_DIR="$HOME/.config/nvim/pack" 

mkdir -p "$NEOVIM_DIR"
mkdir -p "$PLUG_DIR"
mkdir -p "$THEME_DIR"

echo "---Installing system dependencies---"
if [[ "$(uname)" == "Darwin" ]]; then
  echo "Assuming OS is mac"
  brew install ripgrep vim git curl neovim
else
  echo "Assuming OS is linux"
  sudo apt update
  sudo apt install -y ripgrep vim git curl neovim
fi

echo "---Installing fzf binary---"
if [ ! -d "$HOME/.fzf" ]; then
  git clone --depth 1 https://github.com/junegunn/fzf.git ~/.fzf
  ~/.fzf/install --no-key-bindings --no-completion --no-update-rc
else
  echo "fzf already installed"
fi

echo "---Installing fzf.vim---"
git clone --depth 1 https://github.com/junegunn/fzf.vim.git "$PLUG_DIR/fzf.vim"

echo "Linking fzf Vim plugin files..."
ln -sf ~/.fzf/plugin "$PLUG_DIR/fzf"
ln -sf ~/.fzf/autoload "$PLUG_DIR/fzf"

echo "---Installing wiki.vim---"
git clone --depth 1 https://github.com/lervag/wiki.vim.git "$PLUG_DIR/wiki.vim"

echo "---Installing nightfly colorscheme---"
git clone --depth 1 https://github.com/bluz71/vim-nightfly-colors.git "$THEME_DIR/nightfly"

echo "---Link to neovim---"
ln -s ~/.vim/pack ~/.config/nvim/pack

echo "---Set vimrc into neovim"
cat > ~/.config/nvim/init.vim <<EOF
" Neovim compatibility for Vim config
set runtimepath^=~/.vim runtimepath+=~/.vim/after
let &packpath = &runtimepath
EOF

# Being safe
cat .vimrc >> ~/.config/nvim/init.vim

if [[ "$(uname)" == "Darwin" ]]; then
  echo "Assuming OS is mac"
  echo "export FZF_DEFAULT_COMMAND='fd --type f --hidden --ignore-file .ignore'" >> ~/.zshrc
  echo "export FZF_DEFAULT_OPTS='--bind \"ctrl-a:select-all,ctrl-d:deselect-all\"'" >> ~/.zshrc
  echo "Re-run ~/.zshrc"
else
  echo "Assuming OS is linux"
  echo "export FZF_DEFAULT_COMMAND='fd --type f --hidden --ignore-file .ignore'" >> ~/.bashrc
  echo "export FZF_DEFAULT_OPTS='--bind \"ctrl-a:select-all,ctrl-d:deselect-all\"'" >> ~/.bashrc
  echo "Re-run ~/.bashrc"
fi