From d689c9705f25c4714c08b32d8292af08084cdf1a Mon Sep 17 00:00:00 2001 From: David Heinemeier Hansson Date: Sun, 1 Jun 2025 11:39:15 +0200 Subject: [PATCH] Fleshout the default nvim setup --- .../plugins/snacks-animated-scrolling-off.lua | 8 ++++ config/nvim/lua/plugins/theme.lua | 8 ++++ config/nvim/plugin/after/transparency.lua | 45 +++++++++++++++++++ install/configurations.sh | 10 +++-- install/development.sh | 3 +- 5 files changed, 70 insertions(+), 4 deletions(-) create mode 100644 config/nvim/lua/plugins/snacks-animated-scrolling-off.lua create mode 100644 config/nvim/lua/plugins/theme.lua create mode 100644 config/nvim/plugin/after/transparency.lua diff --git a/config/nvim/lua/plugins/snacks-animated-scrolling-off.lua b/config/nvim/lua/plugins/snacks-animated-scrolling-off.lua new file mode 100644 index 0000000..cbb0a58 --- /dev/null +++ b/config/nvim/lua/plugins/snacks-animated-scrolling-off.lua @@ -0,0 +1,8 @@ +return { + "folke/snacks.nvim", + opts = { + scroll = { + enabled = false, -- Disable scrolling animations + }, + }, +} diff --git a/config/nvim/lua/plugins/theme.lua b/config/nvim/lua/plugins/theme.lua new file mode 100644 index 0000000..dad2d30 --- /dev/null +++ b/config/nvim/lua/plugins/theme.lua @@ -0,0 +1,8 @@ +return { + { + "LazyVim/LazyVim", + opts = { + colorscheme = "tokyonight", + }, + }, +} diff --git a/config/nvim/plugin/after/transparency.lua b/config/nvim/plugin/after/transparency.lua new file mode 100644 index 0000000..d0090f0 --- /dev/null +++ b/config/nvim/plugin/after/transparency.lua @@ -0,0 +1,45 @@ +-- transparent background +vim.api.nvim_set_hl(0, "Normal", { bg = "none" }) +vim.api.nvim_set_hl(0, "NormalFloat", { bg = "none" }) +vim.api.nvim_set_hl(0, "FloatBorder", { bg = "none" }) +vim.api.nvim_set_hl(0, "Pmenu", { bg = "none" }) +vim.api.nvim_set_hl(0, "Terminal", { bg = "none" }) +vim.api.nvim_set_hl(0, "EndOfBuffer", { bg = "none" }) +vim.api.nvim_set_hl(0, "FoldColumn", { bg = "none" }) +vim.api.nvim_set_hl(0, "Folded", { bg = "none" }) +vim.api.nvim_set_hl(0, "SignColumn", { bg = "none" }) +vim.api.nvim_set_hl(0, "NormalNC", { bg = "none" }) +vim.api.nvim_set_hl(0, "WhichKeyFloat", { bg = "none" }) +vim.api.nvim_set_hl(0, "TelescopeBorder", { bg = "none" }) +vim.api.nvim_set_hl(0, "TelescopeNormal", { bg = "none" }) +vim.api.nvim_set_hl(0, "TelescopePromptBorder", { bg = "none" }) +vim.api.nvim_set_hl(0, "TelescopePromptTitle", { bg = "none" }) + +-- transparent background for neotree +vim.api.nvim_set_hl(0, "NeoTreeNormal", { bg = "none" }) +vim.api.nvim_set_hl(0, "NeoTreeNormalNC", { bg = "none" }) +vim.api.nvim_set_hl(0, "NeoTreeVertSplit", { bg = "none" }) +vim.api.nvim_set_hl(0, "NeoTreeWinSeparator", { bg = "none" }) +vim.api.nvim_set_hl(0, "NeoTreeEndOfBuffer", { bg = "none" }) + +-- transparent background for nvim-tree +vim.api.nvim_set_hl(0, "NvimTreeNormal", { bg = "none" }) +vim.api.nvim_set_hl(0, "NvimTreeVertSplit", { bg = "none" }) +vim.api.nvim_set_hl(0, "NvimTreeEndOfBuffer", { bg = "none" }) + +-- transparent notify background +vim.api.nvim_set_hl(0, "NotifyINFOBody", { bg = "none" }) +vim.api.nvim_set_hl(0, "NotifyERRORBody", { bg = "none" }) +vim.api.nvim_set_hl(0, "NotifyWARNBody", { bg = "none" }) +vim.api.nvim_set_hl(0, "NotifyTRACEBody", { bg = "none" }) +vim.api.nvim_set_hl(0, "NotifyDEBUGBody", { bg = "none" }) +vim.api.nvim_set_hl(0, "NotifyINFOTitle", { bg = "none" }) +vim.api.nvim_set_hl(0, "NotifyERRORTitle", { bg = "none" }) +vim.api.nvim_set_hl(0, "NotifyWARNTitle", { bg = "none" }) +vim.api.nvim_set_hl(0, "NotifyTRACETitle", { bg = "none" }) +vim.api.nvim_set_hl(0, "NotifyDEBUGTitle", { bg = "none" }) +vim.api.nvim_set_hl(0, "NotifyINFOBorder", { bg = "none" }) +vim.api.nvim_set_hl(0, "NotifyERRORBorder", { bg = "none" }) +vim.api.nvim_set_hl(0, "NotifyWARNBorder", { bg = "none" }) +vim.api.nvim_set_hl(0, "NotifyTRACEBorder", { bg = "none" }) +vim.api.nvim_set_hl(0, "NotifyDEBUGBorder", { bg = "none" }) diff --git a/install/configurations.sh b/install/configurations.sh index 1e297d0..6593316 100644 --- a/install/configurations.sh +++ b/install/configurations.sh @@ -1,5 +1,9 @@ -# Copy over omarchy configs -cp -R ~/.local/share/omarchy/config/* ~/.config/ - # Install LazyVim git clone https://github.com/LazyVim/starter ~/.config/nvim +rm -rf ~/.config/nvim/.git + +# Copy over Omarchy configs +cp -R ~/.local/share/omarchy/config/* ~/.config/ + +# Turn off relative line numbers in nvim +echo "vim.opt.relativenumber = false" >>~/.config/nvim/lua/config/options.lua diff --git a/install/development.sh b/install/development.sh index 2f4e322..810f677 100644 --- a/install/development.sh +++ b/install/development.sh @@ -1,4 +1,5 @@ yay -S --noconfirm \ - nvim mise docker \ + nvim luarocks tree-sitter-cli \ + mise docker \ lazygit lazydocker \ github-cli