From 75e145adeda30b914fa75faf87ee410d826f5bdd Mon Sep 17 00:00:00 2001 From: Dylan Pinn Date: Thu, 19 Dec 2024 15:53:41 +1100 Subject: [PATCH 01/13] chore: move vim to backup directory --- Makefile | 4 +--- {vim => vim.bak}/after/ftplugin/javascript.vim | 0 {vim => vim.bak}/after/ftplugin/json.vim | 0 {vim => vim.bak}/after/ftplugin/markdown.vim | 0 {vim => vim.bak}/after/ftplugin/sh.vim | 0 {vim => vim.bak}/after/ftplugin/txt.vim | 0 {vim => vim.bak}/after/ftplugin/typescript.vim | 0 {vim => vim.bak}/after/ftplugin/vim.vim | 0 {vim => vim.bak}/after/indent/javascript.vim | 0 {vim => vim.bak}/after/indent/json.vim | 0 {vim => vim.bak}/after/indent/markdown.vim | 0 {vim => vim.bak}/after/indent/sh.vim | 0 {vim => vim.bak}/after/indent/typescript.vim | 0 {vim => vim.bak}/after/indent/vim.vim | 0 {vim => vim.bak}/after/indent/yaml.vim | 0 {vim => vim.bak}/autoload/indent.vim | 0 {vim => vim.bak}/compiler/eslint.vim | 0 {vim => vim.bak}/compiler/rubocop.vim | 0 {vim => vim.bak}/compiler/vint.vim | 0 {vim => vim.bak}/ftdetect/brewfile.vim | 0 {vim => vim.bak}/ftdetect/git-config.vim | 0 {vim => vim.bak}/ftdetect/shell-config.vim | 0 {vim => vim.bak}/plugin/disable-builtin-plugins.vim | 0 {vim => vim.bak}/plugin/editorconfig.vim | 0 {vim => vim.bak}/plugin/git-grep.vim | 0 {vim => vim.bak}/plugin/matchit.vim | 0 {vim => vim.bak}/plugin/statusline.vim | 0 {vim => vim.bak}/vimrc | 0 28 files changed, 1 insertion(+), 3 deletions(-) rename {vim => vim.bak}/after/ftplugin/javascript.vim (100%) rename {vim => vim.bak}/after/ftplugin/json.vim (100%) rename {vim => vim.bak}/after/ftplugin/markdown.vim (100%) rename {vim => vim.bak}/after/ftplugin/sh.vim (100%) rename {vim => vim.bak}/after/ftplugin/txt.vim (100%) rename {vim => vim.bak}/after/ftplugin/typescript.vim (100%) rename {vim => vim.bak}/after/ftplugin/vim.vim (100%) rename {vim => vim.bak}/after/indent/javascript.vim (100%) rename {vim => vim.bak}/after/indent/json.vim (100%) rename {vim => vim.bak}/after/indent/markdown.vim (100%) rename {vim => vim.bak}/after/indent/sh.vim (100%) rename {vim => vim.bak}/after/indent/typescript.vim (100%) rename {vim => vim.bak}/after/indent/vim.vim (100%) rename {vim => vim.bak}/after/indent/yaml.vim (100%) rename {vim => vim.bak}/autoload/indent.vim (100%) rename {vim => vim.bak}/compiler/eslint.vim (100%) rename {vim => vim.bak}/compiler/rubocop.vim (100%) rename {vim => vim.bak}/compiler/vint.vim (100%) rename {vim => vim.bak}/ftdetect/brewfile.vim (100%) rename {vim => vim.bak}/ftdetect/git-config.vim (100%) rename {vim => vim.bak}/ftdetect/shell-config.vim (100%) rename {vim => vim.bak}/plugin/disable-builtin-plugins.vim (100%) rename {vim => vim.bak}/plugin/editorconfig.vim (100%) rename {vim => vim.bak}/plugin/git-grep.vim (100%) rename {vim => vim.bak}/plugin/matchit.vim (100%) rename {vim => vim.bak}/plugin/statusline.vim (100%) rename {vim => vim.bak}/vimrc (100%) diff --git a/Makefile b/Makefile index 99aab756e..812cea86b 100644 --- a/Makefile +++ b/Makefile @@ -9,7 +9,6 @@ install-git \ install-sh \ install-tmux \ - install-vim \ install-work \ lint \ lint-bash \ @@ -73,8 +72,7 @@ install: install-bash \ install-mise \ install-npm \ install-nvim \ - install-tmux \ - install-vim + install-tmux install-bash: lint-bash install-sh cp -p -- bash/bash_profile $(HOME)/.bash_profile diff --git a/vim/after/ftplugin/javascript.vim b/vim.bak/after/ftplugin/javascript.vim similarity index 100% rename from vim/after/ftplugin/javascript.vim rename to vim.bak/after/ftplugin/javascript.vim diff --git a/vim/after/ftplugin/json.vim b/vim.bak/after/ftplugin/json.vim similarity index 100% rename from vim/after/ftplugin/json.vim rename to vim.bak/after/ftplugin/json.vim diff --git a/vim/after/ftplugin/markdown.vim b/vim.bak/after/ftplugin/markdown.vim similarity index 100% rename from vim/after/ftplugin/markdown.vim rename to vim.bak/after/ftplugin/markdown.vim diff --git a/vim/after/ftplugin/sh.vim b/vim.bak/after/ftplugin/sh.vim similarity index 100% rename from vim/after/ftplugin/sh.vim rename to vim.bak/after/ftplugin/sh.vim diff --git a/vim/after/ftplugin/txt.vim b/vim.bak/after/ftplugin/txt.vim similarity index 100% rename from vim/after/ftplugin/txt.vim rename to vim.bak/after/ftplugin/txt.vim diff --git a/vim/after/ftplugin/typescript.vim b/vim.bak/after/ftplugin/typescript.vim similarity index 100% rename from vim/after/ftplugin/typescript.vim rename to vim.bak/after/ftplugin/typescript.vim diff --git a/vim/after/ftplugin/vim.vim b/vim.bak/after/ftplugin/vim.vim similarity index 100% rename from vim/after/ftplugin/vim.vim rename to vim.bak/after/ftplugin/vim.vim diff --git a/vim/after/indent/javascript.vim b/vim.bak/after/indent/javascript.vim similarity index 100% rename from vim/after/indent/javascript.vim rename to vim.bak/after/indent/javascript.vim diff --git a/vim/after/indent/json.vim b/vim.bak/after/indent/json.vim similarity index 100% rename from vim/after/indent/json.vim rename to vim.bak/after/indent/json.vim diff --git a/vim/after/indent/markdown.vim b/vim.bak/after/indent/markdown.vim similarity index 100% rename from vim/after/indent/markdown.vim rename to vim.bak/after/indent/markdown.vim diff --git a/vim/after/indent/sh.vim b/vim.bak/after/indent/sh.vim similarity index 100% rename from vim/after/indent/sh.vim rename to vim.bak/after/indent/sh.vim diff --git a/vim/after/indent/typescript.vim b/vim.bak/after/indent/typescript.vim similarity index 100% rename from vim/after/indent/typescript.vim rename to vim.bak/after/indent/typescript.vim diff --git a/vim/after/indent/vim.vim b/vim.bak/after/indent/vim.vim similarity index 100% rename from vim/after/indent/vim.vim rename to vim.bak/after/indent/vim.vim diff --git a/vim/after/indent/yaml.vim b/vim.bak/after/indent/yaml.vim similarity index 100% rename from vim/after/indent/yaml.vim rename to vim.bak/after/indent/yaml.vim diff --git a/vim/autoload/indent.vim b/vim.bak/autoload/indent.vim similarity index 100% rename from vim/autoload/indent.vim rename to vim.bak/autoload/indent.vim diff --git a/vim/compiler/eslint.vim b/vim.bak/compiler/eslint.vim similarity index 100% rename from vim/compiler/eslint.vim rename to vim.bak/compiler/eslint.vim diff --git a/vim/compiler/rubocop.vim b/vim.bak/compiler/rubocop.vim similarity index 100% rename from vim/compiler/rubocop.vim rename to vim.bak/compiler/rubocop.vim diff --git a/vim/compiler/vint.vim b/vim.bak/compiler/vint.vim similarity index 100% rename from vim/compiler/vint.vim rename to vim.bak/compiler/vint.vim diff --git a/vim/ftdetect/brewfile.vim b/vim.bak/ftdetect/brewfile.vim similarity index 100% rename from vim/ftdetect/brewfile.vim rename to vim.bak/ftdetect/brewfile.vim diff --git a/vim/ftdetect/git-config.vim b/vim.bak/ftdetect/git-config.vim similarity index 100% rename from vim/ftdetect/git-config.vim rename to vim.bak/ftdetect/git-config.vim diff --git a/vim/ftdetect/shell-config.vim b/vim.bak/ftdetect/shell-config.vim similarity index 100% rename from vim/ftdetect/shell-config.vim rename to vim.bak/ftdetect/shell-config.vim diff --git a/vim/plugin/disable-builtin-plugins.vim b/vim.bak/plugin/disable-builtin-plugins.vim similarity index 100% rename from vim/plugin/disable-builtin-plugins.vim rename to vim.bak/plugin/disable-builtin-plugins.vim diff --git a/vim/plugin/editorconfig.vim b/vim.bak/plugin/editorconfig.vim similarity index 100% rename from vim/plugin/editorconfig.vim rename to vim.bak/plugin/editorconfig.vim diff --git a/vim/plugin/git-grep.vim b/vim.bak/plugin/git-grep.vim similarity index 100% rename from vim/plugin/git-grep.vim rename to vim.bak/plugin/git-grep.vim diff --git a/vim/plugin/matchit.vim b/vim.bak/plugin/matchit.vim similarity index 100% rename from vim/plugin/matchit.vim rename to vim.bak/plugin/matchit.vim diff --git a/vim/plugin/statusline.vim b/vim.bak/plugin/statusline.vim similarity index 100% rename from vim/plugin/statusline.vim rename to vim.bak/plugin/statusline.vim diff --git a/vim/vimrc b/vim.bak/vimrc similarity index 100% rename from vim/vimrc rename to vim.bak/vimrc From ebe8b6458bb479472d9ec23e0641b83e5dac17ff Mon Sep 17 00:00:00 2001 From: Dylan Pinn Date: Thu, 19 Dec 2024 15:57:42 +1100 Subject: [PATCH 02/13] chore: backup nvim config --- .gitmodules | 14 +++++++------- nvim.bak/.DS_Store | Bin 0 -> 6148 bytes {nvim => nvim.bak}/after/ftplugin/javascript.vim | 0 {nvim => nvim.bak}/after/ftplugin/json.vim | 0 {nvim => nvim.bak}/after/ftplugin/lua.lua | 0 {nvim => nvim.bak}/after/ftplugin/markdown.lua | 0 {nvim => nvim.bak}/after/ftplugin/markdown.vim | 0 {nvim => nvim.bak}/after/ftplugin/sh.lua | 0 {nvim => nvim.bak}/after/ftplugin/sh.vim | 0 {nvim => nvim.bak}/after/ftplugin/txt.vim | 0 {nvim => nvim.bak}/after/ftplugin/typescript.vim | 0 {nvim => nvim.bak}/after/ftplugin/vim.vim | 0 {nvim => nvim.bak}/after/indent/dockerfile.vim | 0 {nvim => nvim.bak}/after/indent/javascript.vim | 0 {nvim => nvim.bak}/after/indent/json.vim | 0 {nvim => nvim.bak}/after/indent/markdown.vim | 0 {nvim => nvim.bak}/after/indent/sh.vim | 0 {nvim => nvim.bak}/after/indent/typescript.vim | 0 {nvim => nvim.bak}/after/indent/vim.vim | 0 {nvim => nvim.bak}/after/indent/yaml.vim | 0 {nvim => nvim.bak}/after/plugin/conform.lua | 0 {nvim => nvim.bak}/after/plugin/lint.lua | 0 {nvim => nvim.bak}/after/plugin/lsp.lua | 0 {nvim => nvim.bak}/after/plugin/treesitter.lua | 0 {nvim => nvim.bak}/autoload/indent.vim | 0 {nvim => nvim.bak}/compiler/eslint.vim | 0 {nvim => nvim.bak}/compiler/luacheck.vim | 0 {nvim => nvim.bak}/compiler/rubocop.vim | 0 {nvim => nvim.bak}/compiler/vint.vim | 0 {nvim => nvim.bak}/ftdetect/brewfile.vim | 0 {nvim => nvim.bak}/ftdetect/git-config.vim | 0 {nvim => nvim.bak}/ftplugin/markdown.vim | 0 {nvim => nvim.bak}/init.lua | 0 {nvim => nvim.bak}/lua/dcp/init.lua | 0 {nvim => nvim.bak}/lua/dcp/keymaps.lua | 0 {nvim => nvim.bak}/lua/dcp/options.lua | 0 {nvim => nvim.bak}/lua/dcp/set-background.lua | 0 .../pack/bundle/start/conform.nvim | 0 {nvim => nvim.bak}/pack/bundle/start/copilot.vim | 0 {nvim => nvim.bak}/pack/bundle/start/dispatch | 0 {nvim => nvim.bak}/pack/bundle/start/nvim-lint | 0 .../pack/bundle/start/nvim-lspconfig | 0 .../pack/bundle/start/nvim-treesitter | 0 .../pack/bundle/start/projectionist | 0 .../plugin/disable-builtin-plugins.vim | 0 {nvim => nvim.bak}/plugin/matchit.vim | 0 46 files changed, 7 insertions(+), 7 deletions(-) create mode 100644 nvim.bak/.DS_Store rename {nvim => nvim.bak}/after/ftplugin/javascript.vim (100%) rename {nvim => nvim.bak}/after/ftplugin/json.vim (100%) rename {nvim => nvim.bak}/after/ftplugin/lua.lua (100%) rename {nvim => nvim.bak}/after/ftplugin/markdown.lua (100%) rename {nvim => nvim.bak}/after/ftplugin/markdown.vim (100%) rename {nvim => nvim.bak}/after/ftplugin/sh.lua (100%) rename {nvim => nvim.bak}/after/ftplugin/sh.vim (100%) rename {nvim => nvim.bak}/after/ftplugin/txt.vim (100%) rename {nvim => nvim.bak}/after/ftplugin/typescript.vim (100%) rename {nvim => nvim.bak}/after/ftplugin/vim.vim (100%) rename {nvim => nvim.bak}/after/indent/dockerfile.vim (100%) rename {nvim => nvim.bak}/after/indent/javascript.vim (100%) rename {nvim => nvim.bak}/after/indent/json.vim (100%) rename {nvim => nvim.bak}/after/indent/markdown.vim (100%) rename {nvim => nvim.bak}/after/indent/sh.vim (100%) rename {nvim => nvim.bak}/after/indent/typescript.vim (100%) rename {nvim => nvim.bak}/after/indent/vim.vim (100%) rename {nvim => nvim.bak}/after/indent/yaml.vim (100%) rename {nvim => nvim.bak}/after/plugin/conform.lua (100%) rename {nvim => nvim.bak}/after/plugin/lint.lua (100%) rename {nvim => nvim.bak}/after/plugin/lsp.lua (100%) rename {nvim => nvim.bak}/after/plugin/treesitter.lua (100%) rename {nvim => nvim.bak}/autoload/indent.vim (100%) rename {nvim => nvim.bak}/compiler/eslint.vim (100%) rename {nvim => nvim.bak}/compiler/luacheck.vim (100%) rename {nvim => nvim.bak}/compiler/rubocop.vim (100%) rename {nvim => nvim.bak}/compiler/vint.vim (100%) rename {nvim => nvim.bak}/ftdetect/brewfile.vim (100%) rename {nvim => nvim.bak}/ftdetect/git-config.vim (100%) rename {nvim => nvim.bak}/ftplugin/markdown.vim (100%) rename {nvim => nvim.bak}/init.lua (100%) rename {nvim => nvim.bak}/lua/dcp/init.lua (100%) rename {nvim => nvim.bak}/lua/dcp/keymaps.lua (100%) rename {nvim => nvim.bak}/lua/dcp/options.lua (100%) rename {nvim => nvim.bak}/lua/dcp/set-background.lua (100%) rename {nvim => nvim.bak}/pack/bundle/start/conform.nvim (100%) rename {nvim => nvim.bak}/pack/bundle/start/copilot.vim (100%) rename {nvim => nvim.bak}/pack/bundle/start/dispatch (100%) rename {nvim => nvim.bak}/pack/bundle/start/nvim-lint (100%) rename {nvim => nvim.bak}/pack/bundle/start/nvim-lspconfig (100%) rename {nvim => nvim.bak}/pack/bundle/start/nvim-treesitter (100%) rename {nvim => nvim.bak}/pack/bundle/start/projectionist (100%) rename {nvim => nvim.bak}/plugin/disable-builtin-plugins.vim (100%) rename {nvim => nvim.bak}/plugin/matchit.vim (100%) diff --git a/.gitmodules b/.gitmodules index 86b7f1084..63c8b695b 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,21 +1,21 @@ [submodule "nvim/pack/bundle/start/nvim-treesitter"] - path = nvim/pack/bundle/start/nvim-treesitter + path = nvim.bak/pack/bundle/start/nvim-treesitter url = https://github.com/nvim-treesitter/nvim-treesitter [submodule "nvim/pack/bundle/start/nvim-lspconfig"] - path = nvim/pack/bundle/start/nvim-lspconfig + path = nvim.bak/pack/bundle/start/nvim-lspconfig url = https://github.com/neovim/nvim-lspconfig [submodule "nvim/pack/bundle/start/projectionist"] - path = nvim/pack/bundle/start/projectionist + path = nvim.bak/pack/bundle/start/projectionist url = https://tpope.io/vim/projectionist.git [submodule "nvim/pack/bundle/start/dispatch"] - path = nvim/pack/bundle/start/dispatch + path = nvim.bak/pack/bundle/start/dispatch url = https://tpope.io/vim/dispatch.git [submodule "nvim/pack/bundle/start/copilot.vim"] - path = nvim/pack/bundle/start/copilot.vim + path = nvim.bak/pack/bundle/start/copilot.vim url = https://github.com/github/copilot.vim.git [submodule "nvim/pack/bundle/start/conform.nvim"] - path = nvim/pack/bundle/start/conform.nvim + path = nvim.bak/pack/bundle/start/conform.nvim url = https://github.com/stevearc/conform.nvim.git [submodule "nvim/pack/bundle/start/nvim-lint"] - path = nvim/pack/bundle/start/nvim-lint + path = nvim.bak/pack/bundle/start/nvim-lint url = https://github.com/mfussenegger/nvim-lint.git diff --git a/nvim.bak/.DS_Store b/nvim.bak/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..d1ca0806a8d9310f8a86a645f9c6a005519958d1 GIT binary patch literal 6148 zcmeHKu}T9$5S=ww1Z`4USZpP>`GYf@U@7DWG>Jwb=N*#tC)oHK{(%1=;-A17_3BP26o?Oc4p`0h3woBksB-~eWD%_buk!|ZA@#7_j$BzD|k5B$r)EPqjS2M zP5Z-Ev^h)xQ{cBLpclZH3d*UZ=>Iz|@>0nr&%iFN#N>I>vEOD<{9S?`4F znf+}A(6iaPJBl`&0;Yf|uvCEW2amy+2CNk2>cAwg0Kf!pF|4H*0X;i_X~0Sm9+=Zq zpr$%>RrO0c{62h616GQfPEIQ0oKV??Hx#Godfvh!p7Py2t(h=zoVR*LYz P>_I?eu*nqoQ3XB$?--i9 literal 0 HcmV?d00001 diff --git a/nvim/after/ftplugin/javascript.vim b/nvim.bak/after/ftplugin/javascript.vim similarity index 100% rename from nvim/after/ftplugin/javascript.vim rename to nvim.bak/after/ftplugin/javascript.vim diff --git a/nvim/after/ftplugin/json.vim b/nvim.bak/after/ftplugin/json.vim similarity index 100% rename from nvim/after/ftplugin/json.vim rename to nvim.bak/after/ftplugin/json.vim diff --git a/nvim/after/ftplugin/lua.lua b/nvim.bak/after/ftplugin/lua.lua similarity index 100% rename from nvim/after/ftplugin/lua.lua rename to nvim.bak/after/ftplugin/lua.lua diff --git a/nvim/after/ftplugin/markdown.lua b/nvim.bak/after/ftplugin/markdown.lua similarity index 100% rename from nvim/after/ftplugin/markdown.lua rename to nvim.bak/after/ftplugin/markdown.lua diff --git a/nvim/after/ftplugin/markdown.vim b/nvim.bak/after/ftplugin/markdown.vim similarity index 100% rename from nvim/after/ftplugin/markdown.vim rename to nvim.bak/after/ftplugin/markdown.vim diff --git a/nvim/after/ftplugin/sh.lua b/nvim.bak/after/ftplugin/sh.lua similarity index 100% rename from nvim/after/ftplugin/sh.lua rename to nvim.bak/after/ftplugin/sh.lua diff --git a/nvim/after/ftplugin/sh.vim b/nvim.bak/after/ftplugin/sh.vim similarity index 100% rename from nvim/after/ftplugin/sh.vim rename to nvim.bak/after/ftplugin/sh.vim diff --git a/nvim/after/ftplugin/txt.vim b/nvim.bak/after/ftplugin/txt.vim similarity index 100% rename from nvim/after/ftplugin/txt.vim rename to nvim.bak/after/ftplugin/txt.vim diff --git a/nvim/after/ftplugin/typescript.vim b/nvim.bak/after/ftplugin/typescript.vim similarity index 100% rename from nvim/after/ftplugin/typescript.vim rename to nvim.bak/after/ftplugin/typescript.vim diff --git a/nvim/after/ftplugin/vim.vim b/nvim.bak/after/ftplugin/vim.vim similarity index 100% rename from nvim/after/ftplugin/vim.vim rename to nvim.bak/after/ftplugin/vim.vim diff --git a/nvim/after/indent/dockerfile.vim b/nvim.bak/after/indent/dockerfile.vim similarity index 100% rename from nvim/after/indent/dockerfile.vim rename to nvim.bak/after/indent/dockerfile.vim diff --git a/nvim/after/indent/javascript.vim b/nvim.bak/after/indent/javascript.vim similarity index 100% rename from nvim/after/indent/javascript.vim rename to nvim.bak/after/indent/javascript.vim diff --git a/nvim/after/indent/json.vim b/nvim.bak/after/indent/json.vim similarity index 100% rename from nvim/after/indent/json.vim rename to nvim.bak/after/indent/json.vim diff --git a/nvim/after/indent/markdown.vim b/nvim.bak/after/indent/markdown.vim similarity index 100% rename from nvim/after/indent/markdown.vim rename to nvim.bak/after/indent/markdown.vim diff --git a/nvim/after/indent/sh.vim b/nvim.bak/after/indent/sh.vim similarity index 100% rename from nvim/after/indent/sh.vim rename to nvim.bak/after/indent/sh.vim diff --git a/nvim/after/indent/typescript.vim b/nvim.bak/after/indent/typescript.vim similarity index 100% rename from nvim/after/indent/typescript.vim rename to nvim.bak/after/indent/typescript.vim diff --git a/nvim/after/indent/vim.vim b/nvim.bak/after/indent/vim.vim similarity index 100% rename from nvim/after/indent/vim.vim rename to nvim.bak/after/indent/vim.vim diff --git a/nvim/after/indent/yaml.vim b/nvim.bak/after/indent/yaml.vim similarity index 100% rename from nvim/after/indent/yaml.vim rename to nvim.bak/after/indent/yaml.vim diff --git a/nvim/after/plugin/conform.lua b/nvim.bak/after/plugin/conform.lua similarity index 100% rename from nvim/after/plugin/conform.lua rename to nvim.bak/after/plugin/conform.lua diff --git a/nvim/after/plugin/lint.lua b/nvim.bak/after/plugin/lint.lua similarity index 100% rename from nvim/after/plugin/lint.lua rename to nvim.bak/after/plugin/lint.lua diff --git a/nvim/after/plugin/lsp.lua b/nvim.bak/after/plugin/lsp.lua similarity index 100% rename from nvim/after/plugin/lsp.lua rename to nvim.bak/after/plugin/lsp.lua diff --git a/nvim/after/plugin/treesitter.lua b/nvim.bak/after/plugin/treesitter.lua similarity index 100% rename from nvim/after/plugin/treesitter.lua rename to nvim.bak/after/plugin/treesitter.lua diff --git a/nvim/autoload/indent.vim b/nvim.bak/autoload/indent.vim similarity index 100% rename from nvim/autoload/indent.vim rename to nvim.bak/autoload/indent.vim diff --git a/nvim/compiler/eslint.vim b/nvim.bak/compiler/eslint.vim similarity index 100% rename from nvim/compiler/eslint.vim rename to nvim.bak/compiler/eslint.vim diff --git a/nvim/compiler/luacheck.vim b/nvim.bak/compiler/luacheck.vim similarity index 100% rename from nvim/compiler/luacheck.vim rename to nvim.bak/compiler/luacheck.vim diff --git a/nvim/compiler/rubocop.vim b/nvim.bak/compiler/rubocop.vim similarity index 100% rename from nvim/compiler/rubocop.vim rename to nvim.bak/compiler/rubocop.vim diff --git a/nvim/compiler/vint.vim b/nvim.bak/compiler/vint.vim similarity index 100% rename from nvim/compiler/vint.vim rename to nvim.bak/compiler/vint.vim diff --git a/nvim/ftdetect/brewfile.vim b/nvim.bak/ftdetect/brewfile.vim similarity index 100% rename from nvim/ftdetect/brewfile.vim rename to nvim.bak/ftdetect/brewfile.vim diff --git a/nvim/ftdetect/git-config.vim b/nvim.bak/ftdetect/git-config.vim similarity index 100% rename from nvim/ftdetect/git-config.vim rename to nvim.bak/ftdetect/git-config.vim diff --git a/nvim/ftplugin/markdown.vim b/nvim.bak/ftplugin/markdown.vim similarity index 100% rename from nvim/ftplugin/markdown.vim rename to nvim.bak/ftplugin/markdown.vim diff --git a/nvim/init.lua b/nvim.bak/init.lua similarity index 100% rename from nvim/init.lua rename to nvim.bak/init.lua diff --git a/nvim/lua/dcp/init.lua b/nvim.bak/lua/dcp/init.lua similarity index 100% rename from nvim/lua/dcp/init.lua rename to nvim.bak/lua/dcp/init.lua diff --git a/nvim/lua/dcp/keymaps.lua b/nvim.bak/lua/dcp/keymaps.lua similarity index 100% rename from nvim/lua/dcp/keymaps.lua rename to nvim.bak/lua/dcp/keymaps.lua diff --git a/nvim/lua/dcp/options.lua b/nvim.bak/lua/dcp/options.lua similarity index 100% rename from nvim/lua/dcp/options.lua rename to nvim.bak/lua/dcp/options.lua diff --git a/nvim/lua/dcp/set-background.lua b/nvim.bak/lua/dcp/set-background.lua similarity index 100% rename from nvim/lua/dcp/set-background.lua rename to nvim.bak/lua/dcp/set-background.lua diff --git a/nvim/pack/bundle/start/conform.nvim b/nvim.bak/pack/bundle/start/conform.nvim similarity index 100% rename from nvim/pack/bundle/start/conform.nvim rename to nvim.bak/pack/bundle/start/conform.nvim diff --git a/nvim/pack/bundle/start/copilot.vim b/nvim.bak/pack/bundle/start/copilot.vim similarity index 100% rename from nvim/pack/bundle/start/copilot.vim rename to nvim.bak/pack/bundle/start/copilot.vim diff --git a/nvim/pack/bundle/start/dispatch b/nvim.bak/pack/bundle/start/dispatch similarity index 100% rename from nvim/pack/bundle/start/dispatch rename to nvim.bak/pack/bundle/start/dispatch diff --git a/nvim/pack/bundle/start/nvim-lint b/nvim.bak/pack/bundle/start/nvim-lint similarity index 100% rename from nvim/pack/bundle/start/nvim-lint rename to nvim.bak/pack/bundle/start/nvim-lint diff --git a/nvim/pack/bundle/start/nvim-lspconfig b/nvim.bak/pack/bundle/start/nvim-lspconfig similarity index 100% rename from nvim/pack/bundle/start/nvim-lspconfig rename to nvim.bak/pack/bundle/start/nvim-lspconfig diff --git a/nvim/pack/bundle/start/nvim-treesitter b/nvim.bak/pack/bundle/start/nvim-treesitter similarity index 100% rename from nvim/pack/bundle/start/nvim-treesitter rename to nvim.bak/pack/bundle/start/nvim-treesitter diff --git a/nvim/pack/bundle/start/projectionist b/nvim.bak/pack/bundle/start/projectionist similarity index 100% rename from nvim/pack/bundle/start/projectionist rename to nvim.bak/pack/bundle/start/projectionist diff --git a/nvim/plugin/disable-builtin-plugins.vim b/nvim.bak/plugin/disable-builtin-plugins.vim similarity index 100% rename from nvim/plugin/disable-builtin-plugins.vim rename to nvim.bak/plugin/disable-builtin-plugins.vim diff --git a/nvim/plugin/matchit.vim b/nvim.bak/plugin/matchit.vim similarity index 100% rename from nvim/plugin/matchit.vim rename to nvim.bak/plugin/matchit.vim From ff4238268268a444fc8593bab83452808dabe3f5 Mon Sep 17 00:00:00 2001 From: Dylan Pinn Date: Thu, 19 Dec 2024 16:15:57 +1100 Subject: [PATCH 03/13] feat(nvim): start setting up new config Trying out somethig different for a change as I don't have a big appetite for configuration. --- nvim/init.lua | 1 + nvim/lua/config/lazy.lua | 35 +++++++++++++++++++++++++++++++++ nvim/lua/plugins/tokyonight.lua | 9 +++++++++ 3 files changed, 45 insertions(+) create mode 100644 nvim/init.lua create mode 100644 nvim/lua/config/lazy.lua create mode 100644 nvim/lua/plugins/tokyonight.lua diff --git a/nvim/init.lua b/nvim/init.lua new file mode 100644 index 000000000..55b8979f7 --- /dev/null +++ b/nvim/init.lua @@ -0,0 +1 @@ +require("config.lazy") diff --git a/nvim/lua/config/lazy.lua b/nvim/lua/config/lazy.lua new file mode 100644 index 000000000..c381a4b6b --- /dev/null +++ b/nvim/lua/config/lazy.lua @@ -0,0 +1,35 @@ +-- Bootstrap lazy.nvim +local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim" +if not (vim.uv or vim.loop).fs_stat(lazypath) then + local lazyrepo = "https://github.com/folke/lazy.nvim.git" + local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath }) + if vim.v.shell_error ~= 0 then + vim.api.nvim_echo({ + { "Failed to clone lazy.nvim:\n", "ErrorMsg" }, + { out, "WarningMsg" }, + { "\nPress any key to exit..." }, + }, true, {}) + vim.fn.getchar() + os.exit(1) + end +end +vim.opt.rtp:prepend(lazypath) + +-- Make sure to setup `mapleader` and `maplocalleader` before +-- loading lazy.nvim so that mappings are correct. +-- This is also a good place to setup other settings (vim.opt) +vim.g.mapleader = " " +vim.g.maplocalleader = "\\" + +-- Setup lazy.nvim +require("lazy").setup({ + spec = { + -- import your plugins + { import = "plugins" }, + }, + -- Configure any other settings here. See the documentation for more details. + -- colorscheme that will be used when installing plugins. + install = { colorscheme = { "habamax" } }, + -- automatically check for plugin updates + checker = { enabled = true }, +}) diff --git a/nvim/lua/plugins/tokyonight.lua b/nvim/lua/plugins/tokyonight.lua new file mode 100644 index 000000000..cfe3eaede --- /dev/null +++ b/nvim/lua/plugins/tokyonight.lua @@ -0,0 +1,9 @@ +return { + "folke/tokyonight.nvim", + lazy = false, -- make sure we load this during startup if it is your main colorscheme + priority = 1000, -- make sure to load this before all the other start plugins + config = function() + -- load the colorscheme here + vim.cmd([[colorscheme tokyonight]]) + end, +} From f2703f452824a580c62f2660b9674ea7a2fff152 Mon Sep 17 00:00:00 2001 From: Dylan Pinn Date: Thu, 19 Dec 2024 16:17:55 +1100 Subject: [PATCH 04/13] feat(sh): use Neovim as default visual editor --- sh/profile.d/visual.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sh/profile.d/visual.sh b/sh/profile.d/visual.sh index a6bb6d331..c25796185 100644 --- a/sh/profile.d/visual.sh +++ b/sh/profile.d/visual.sh @@ -1,5 +1,5 @@ # shellcheck shell=sh # Use vi as basic visual editor that should be installed most systems. -VISUAL="vi" +VISUAL="nvim" export VISUAL From 60653eefeb3b8f0adb0da934e89640e084a96c2c Mon Sep 17 00:00:00 2001 From: Dylan Pinn Date: Thu, 19 Dec 2024 22:37:33 +1100 Subject: [PATCH 05/13] feat(nvim): add fzf-lua config --- nvim/lua/plugins/fzf.lua | 19 +++++++++++++++++++ nvim/lua/plugins/tokyonight.lua | 16 +++++++++------- 2 files changed, 28 insertions(+), 7 deletions(-) create mode 100644 nvim/lua/plugins/fzf.lua diff --git a/nvim/lua/plugins/fzf.lua b/nvim/lua/plugins/fzf.lua new file mode 100644 index 000000000..04f5da14f --- /dev/null +++ b/nvim/lua/plugins/fzf.lua @@ -0,0 +1,19 @@ +return { + { + "ibhagwan/fzf-lua", + cmd = "FzfLua", -- lazy load when invoked. + -- optional for icon support + dependencies = { "nvim-tree/nvim-web-devicons" }, + config = function() + -- calling `setup` is optional for customization + require("fzf-lua").setup({}) + end, + keys = { + { "", "FzfLua files" }, + { "/", "FzfLua live_grep" }, + { ":", "FzfLua command_history" }, + { "/", "FzfLua buffers" }, + { "", "FzfLua helptags" }, + }, + }, +} diff --git a/nvim/lua/plugins/tokyonight.lua b/nvim/lua/plugins/tokyonight.lua index cfe3eaede..59589ec89 100644 --- a/nvim/lua/plugins/tokyonight.lua +++ b/nvim/lua/plugins/tokyonight.lua @@ -1,9 +1,11 @@ return { - "folke/tokyonight.nvim", - lazy = false, -- make sure we load this during startup if it is your main colorscheme - priority = 1000, -- make sure to load this before all the other start plugins - config = function() - -- load the colorscheme here - vim.cmd([[colorscheme tokyonight]]) - end, + { + "folke/tokyonight.nvim", + lazy = false, -- make sure we load this during startup if it is your main colorscheme + priority = 1000, -- make sure to load this before all the other start plugins + config = function() + -- load the colorscheme here + vim.cmd([[colorscheme tokyonight]]) + end, + }, } From f1a20498fbe7b8b632ea99427569fbef938757e7 Mon Sep 17 00:00:00 2001 From: Dylan Pinn Date: Thu, 19 Dec 2024 23:30:19 +1100 Subject: [PATCH 06/13] feat(nvim): setup LSP and completion using blink --- nvim/lua/plugins/blink.lua | 30 +++++++++++++++ nvim/lua/plugins/lsp-config.lua | 68 +++++++++++++++++++++++++++++++++ 2 files changed, 98 insertions(+) create mode 100644 nvim/lua/plugins/blink.lua create mode 100644 nvim/lua/plugins/lsp-config.lua diff --git a/nvim/lua/plugins/blink.lua b/nvim/lua/plugins/blink.lua new file mode 100644 index 000000000..e96673a42 --- /dev/null +++ b/nvim/lua/plugins/blink.lua @@ -0,0 +1,30 @@ +return { + { + "saghen/blink.cmp", + -- optional: provides snippets for the snippet source + dependencies = "rafamadriz/friendly-snippets", + + -- use a release tag to download pre-built binaries + version = "v0.*", + opts = { + keymap = { preset = "default" }, + + appearance = { + use_nvim_cmp_as_default = true, + nerd_font_variant = "mono", + }, + + sources = { + default = { "lsp", "path", "snippets", "buffer", "lazydev" }, + }, + providers = { + -- dont show LuaLS require statements when lazydev has items + lsp = { fallback_for = { "lazydev" } }, + lazydev = { name = "LazyDev", module = "lazydev.integrations.blink" }, + }, + + signature = { enabled = true }, + }, + opts_extend = { "sources.default" }, + }, +} diff --git a/nvim/lua/plugins/lsp-config.lua b/nvim/lua/plugins/lsp-config.lua new file mode 100644 index 000000000..09f4cf8d3 --- /dev/null +++ b/nvim/lua/plugins/lsp-config.lua @@ -0,0 +1,68 @@ +return { + -- lspconfig + { + "neovim/nvim-lspconfig", + dependencies = { + { + "folke/lazydev.nvim", + ft = "lua", -- only load on lua files + cmd = "LazyDev", + opts = { + library = { + -- See the configuration section for more details + -- Load luvit types when the `vim.uv` word is found + { path = "${3rd}/luv/library", words = { "vim%.uv" } }, + }, + }, + }, + }, + config = function() + local lspconfig = require("lspconfig") + + lspconfig.lua_ls.setup({ + on_init = function(client) + if client.workspace_folders then + local path = client.workspace_folders[1].name + if vim.loop.fs_stat(path .. "/.luarc.json") or vim.loop.fs_stat(path .. "/.luarc.jsonc") then + return + end + end + + client.config.settings.Lua = vim.tbl_deep_extend("force", client.config.settings.Lua, { + runtime = { + version = "LuaJIT", + }, + -- Make the server aware of Neovim runtime files + workspace = { + checkThirdParty = false, + library = { + vim.env.VIMRUNTIME, + }, + }, + }) + end, + settings = { + Lua = { + codeLens = { + enable = true, + }, + completion = { + callSnippet = "Replace", + }, + doc = { + privateName = { "^_" }, + }, + hint = { + enable = true, + setType = false, + paramType = true, + paramName = "Disable", + semicolon = "Disable", + arrayIndex = "Disable", + }, + }, + }, + }) + end, + }, +} From dc0abcbc2431a51c3120e50bcb4e28f00666f59c Mon Sep 17 00:00:00 2001 From: Dylan Pinn Date: Fri, 20 Dec 2024 00:23:28 +1100 Subject: [PATCH 07/13] feat(nvim): setup conform.nvim --- nvim/lua/plugins/conform.lua | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 nvim/lua/plugins/conform.lua diff --git a/nvim/lua/plugins/conform.lua b/nvim/lua/plugins/conform.lua new file mode 100644 index 000000000..3ca971e2f --- /dev/null +++ b/nvim/lua/plugins/conform.lua @@ -0,0 +1,14 @@ +return { + { + "stevearc/conform.nvim", + init = function() + vim.o.formatexpr = "v:lua.require'conform'.formatexpr()" + end, + opts = { + formatters_by_ft = { + lua = { "stylua" }, + -- typescript = { { "prettierd", "prettier" }, "eslint_d" }, + }, + }, + }, +} From 32ee9fd46950ec1ef63f4b4efe9d0671ec1d587d Mon Sep 17 00:00:00 2001 From: Dylan Pinn Date: Fri, 20 Dec 2024 00:34:01 +1100 Subject: [PATCH 08/13] feat(nvim): setup linting --- nvim/lua/plugins/conform.lua | 5 +++++ nvim/lua/plugins/lint.lua | 17 +++++++++++++++++ 2 files changed, 22 insertions(+) create mode 100644 nvim/lua/plugins/lint.lua diff --git a/nvim/lua/plugins/conform.lua b/nvim/lua/plugins/conform.lua index 3ca971e2f..9dbdf4e46 100644 --- a/nvim/lua/plugins/conform.lua +++ b/nvim/lua/plugins/conform.lua @@ -9,6 +9,11 @@ return { lua = { "stylua" }, -- typescript = { { "prettierd", "prettier" }, "eslint_d" }, }, + format_on_save = { + -- These options will be passed to conform.format() + timeout_ms = 500, + lsp_format = "fallback", + }, }, }, } diff --git a/nvim/lua/plugins/lint.lua b/nvim/lua/plugins/lint.lua new file mode 100644 index 000000000..065b1ea86 --- /dev/null +++ b/nvim/lua/plugins/lint.lua @@ -0,0 +1,17 @@ +return { + { + "mfussenegger/nvim-lint", + init = function() + vim.api.nvim_create_autocmd({ "BufWritePost" }, { + callback = function() + require("lint").try_lint() + end, + }) + end, + config = function() + require("lint").linters_by_ft = { + lua = { "luacheck" }, + } + end, + }, +} From 4f84d3191f24124bfbc7300b5215c35f8d6939d6 Mon Sep 17 00:00:00 2001 From: Dylan Pinn Date: Fri, 20 Dec 2024 00:34:36 +1100 Subject: [PATCH 09/13] chore: rename lsp-config -> lsp --- nvim/lua/plugins/{lsp-config.lua => lsp.lua} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename nvim/lua/plugins/{lsp-config.lua => lsp.lua} (100%) diff --git a/nvim/lua/plugins/lsp-config.lua b/nvim/lua/plugins/lsp.lua similarity index 100% rename from nvim/lua/plugins/lsp-config.lua rename to nvim/lua/plugins/lsp.lua From 2d764c4bdd344c773d32a79d71735c9b944eaa02 Mon Sep 17 00:00:00 2001 From: Dylan Pinn Date: Fri, 20 Dec 2024 00:42:14 +1100 Subject: [PATCH 10/13] fix(nvim): add keymaps for LSP --- nvim/lua/plugins/lsp.lua | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/nvim/lua/plugins/lsp.lua b/nvim/lua/plugins/lsp.lua index 09f4cf8d3..63bc6a99a 100644 --- a/nvim/lua/plugins/lsp.lua +++ b/nvim/lua/plugins/lsp.lua @@ -16,6 +16,42 @@ return { }, }, }, + init = function() + -- Global mappings. + -- See `:help vim.diagnostic.*` for documentation on any of the below functions + -- vim.keymap.set("n", "e", vim.diagnostic.open_float) + -- vim.keymap.set("n", "[d", vim.diagnostic.goto_prev) + -- vim.keymap.set("n", "]d", vim.diagnostic.goto_next) + vim.keymap.set("n", "q", vim.diagnostic.setloclist) + + -- Use LspAttach autocommand to only map the following keys + -- after the language server attaches to the current buffer + vim.api.nvim_create_autocmd("LspAttach", { + group = vim.api.nvim_create_augroup("UserLspConfig", {}), + callback = function(ev) + -- Enable completion triggered by + -- vim.bo[ev.buf].omnifunc = "v:lua.vim.lsp.omnifunc" + + -- Buffer local mappings. + -- See `:help vim.lsp.*` for documentation on any of the below functions + local opts = { buffer = ev.buf } + vim.keymap.set("n", "gD", vim.lsp.buf.declaration, opts) + vim.keymap.set("n", "gd", vim.lsp.buf.definition, opts) + -- vim.keymap.set("n", "K", vim.lsp.buf.hover, opts) + vim.keymap.set("n", "gi", vim.lsp.buf.implementation, opts) + vim.keymap.set("n", "", vim.lsp.buf.signature_help, opts) + vim.keymap.set("n", "wa", vim.lsp.buf.add_workspace_folder, opts) + vim.keymap.set("n", "wr", vim.lsp.buf.remove_workspace_folder, opts) + vim.keymap.set("n", "wl", function() + print(vim.inspect(vim.lsp.buf.list_workspace_folders())) + end, opts) + vim.keymap.set("n", "D", vim.lsp.buf.type_definition, opts) + vim.keymap.set("n", "rn", vim.lsp.buf.rename, opts) + vim.keymap.set({ "n", "v" }, "ca", vim.lsp.buf.code_action, opts) + vim.keymap.set("n", "gr", vim.lsp.buf.references, opts) + end, + }) + end, config = function() local lspconfig = require("lspconfig") From 4ad1892757b6b01e10bf263a61dce32b23464414 Mon Sep 17 00:00:00 2001 From: Dylan Pinn Date: Fri, 20 Dec 2024 00:47:53 +1100 Subject: [PATCH 11/13] feat(nvim): add tree-sitter --- nvim/lua/plugins/treesitter.lua | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 nvim/lua/plugins/treesitter.lua diff --git a/nvim/lua/plugins/treesitter.lua b/nvim/lua/plugins/treesitter.lua new file mode 100644 index 000000000..f17d77f8d --- /dev/null +++ b/nvim/lua/plugins/treesitter.lua @@ -0,0 +1,28 @@ +return { + { + "nvim-treesitter/nvim-treesitter", + version = false, -- last release is way too old and doesn't work on Windows + build = ":TSUpdate", + opts = { + -- A list of parser names, or "all" + ensure_installed = { "lua" }, + + -- Install parsers synchronously (only applied to `ensure_installed`) + sync_install = false, + + -- Automatically install missing parsers when entering buffer + -- Recommendation: set to false if you don't have `tree-sitter` CLI installed locally + auto_install = true, + + highlight = { + enable = true, + + -- Setting this to true will run `:h syntax` and tree-sitter at the same time. + -- Set this to `true` if you depend on 'syntax' being enabled (like for indentation). + -- Using this option may slow down your editor, and you may see some duplicate highlights. + -- Instead of true it can also be a list of languages + additional_vim_regex_highlighting = false, + }, + }, + }, +} From 637c953f0694968adfeb9196a8f7be2ea1bf558a Mon Sep 17 00:00:00 2001 From: Dylan Pinn Date: Fri, 20 Dec 2024 00:58:59 +1100 Subject: [PATCH 12/13] chore(brew): update installed apps --- homebrew/work.Brewfile | 93 ++++++++++++++++++++++++++++----- nvim/lua/plugins/tokyonight.lua | 2 +- 2 files changed, 80 insertions(+), 15 deletions(-) diff --git a/homebrew/work.Brewfile b/homebrew/work.Brewfile index 4cf1971f2..9f876470f 100644 --- a/homebrew/work.Brewfile +++ b/homebrew/work.Brewfile @@ -3,6 +3,16 @@ tap "espanso/espanso" tap "homebrew/bundle" tap "homebrew/cask-fonts" tap "reainternal/stable", "git@git.realestate.com.au:cowbell/homebrew-stuff" +# Macro processing language +brew "m4", link: true +# Automatic configure script builder +brew "autoconf" +# Cryptography and SSL/TLS Toolkit +brew "openssl@3" +# YAML Parser +brew "libyaml" +# Library for command-line editing +brew "readline" # CLI tool to build, test, debug, and deploy Serverless applications using AWS SAM brew "aws-sam-cli" # Official Amazon AWS command-line interface @@ -11,16 +21,34 @@ brew "awscli" brew "bash" # Programmable completion for Bash 4.2+ brew "bash-completion@2" +# Clone of cat(1) with syntax highlighting and Git integration +brew "bat" +# Versatile and fast Unicode/ASCII/ANSI graphics renderer +brew "chafa" # Create and view interactive cheat sheets for *nix commands brew "cheat" # Statistics utility to count lines of code brew "cloc" +# Diff that understands syntax +brew "difftastic" # Docker Credential Helper for Amazon ECR brew "docker-credential-helper-ecr" +# Pluggable and configurable code formatting platform written in Rust +brew "dprint" +# Simple, fast and user-friendly alternative to find +brew "fd" +# Command-line fuzzy finder written in Go +brew "fzf" # GitHub command-line tool brew "gh" # Distributed revision control system brew "git" +# Syntax-highlighting pager for git and diff output +brew "git-delta" +# GNU multiple precision arithmetic library +brew "gmp" +# GNU Pretty Good Privacy (PGP) package +brew "gnupg" # Smarter Dockerfile linter to validate best practices brew "hadolint" # Post-modern modal text editor @@ -31,22 +59,26 @@ brew "htop" brew "hyperfine" # Lightweight and flexible command-line JSON processor brew "jq" +# Simple terminal UI for git commands +brew "lazygit" # Postgres C API library brew "libpq", link: true # Language Server for the Lua language brew "lua-language-server" # Tool for linting and static analysis of Lua code brew "luacheck" -# Macro processing language -brew "m4", link: true +# Package manager for the Lua programming language +brew "luarocks" # Mac App Store command-line interface brew "mas" # Polyglot runtime manager (asdf rust clone) brew "mise" # Ambitious Vim-fork focused on extensibility and agility -brew "neovim", args: ["HEAD"] +brew "neovim" # Search tool like grep and The Silver Searcher brew "ripgrep" +# Safe, concurrent, practical language +brew "rust" # Static analysis and lint tool, for (ba)sh scripts brew "shellcheck" # Autoformat shell script source code @@ -61,6 +93,8 @@ brew "tldr" brew "tmux" # Display directories as trees (with optional color/HTML output) brew "tree" +# Syntax-aware linter for prose +brew "vale" # Vi 'workalike' with many additional features brew "vim" # Vim script Language Lint @@ -69,8 +103,6 @@ brew "vint" brew "yt-dlp" # Login to REA AWS console by switching roles brew "reainternal/stable/aws-switch" -# Authenticate to REA AWS accounts -brew "reainternal/stable/rea-as" # Password manager that keeps all passwords secure behind one password cask "1password" # Professional graphic design software @@ -79,6 +111,8 @@ cask "affinity-designer" cask "affinity-photo" # Professional desktop publishing software cask "affinity-publisher" +# GPU-accelerated terminal emulator +cask "alacritty" # Application launcher and productivity software cask "alfred" # Application uninstaller @@ -93,18 +127,18 @@ cask "bbedit" cask "betterdisplay" # Record and process your ideas cask "bike" +# Opensource IDE for exploring and testing api's +cask "bruno" # Free and open-source web browser cask "chromium" # Screen capturing tool cask "cleanshot" -# The Ultimate Homebrew Companion +# GUI companion app for Homebrew cask "cork" # API documentation browser and code snippet manager cask "dash" # App to build and share containerised applications and microservices cask "docker" -# Cross-platform Text Expander written in Rust -cask "espanso" # Web browser cask "firefox" cask "font-fira-mono" @@ -114,6 +148,7 @@ cask "font-ibm-plex-mono" cask "font-input" cask "font-intel-one-mono" cask "font-jetbrains-mono" +cask "font-jetbrains-mono-nerd-font" cask "font-monaspace" cask "font-roboto-mono" cask "font-source-code-pro" @@ -127,20 +162,30 @@ cask "ia-presenter" cask "iina" # Tool to optimise images to a smaller size cask "imageoptim" +# System monitoring app +cask "istat-menus" +# Terminal emulator as alternative to Apple's Terminal app +cask "iterm2" # JetBrains tools manager cask "jetbrains-toolbox" # Menu bar manager cask "jordanbaird-ice" +# Spot and merge differences in text and image files or folders +cask "kaleidoscope@2" # Automation software cask "keyboard-maestro" +# GPU-based terminal emulator +cask "kitty" # Software for Logitech devices -cask "logi-options-plus" +cask "logi-options+" # Optimise your webcam, headset, and Logi Dock for video meetings cask "logitune" -# Web browser +# Multi-platform web browser cask "microsoft-edge" # Tool to create text-based art cask "monodraw" +# Utility to move and zoom windows—on one display +cask "moom" # Native code editor cask "nova" # WebKit based web browser @@ -151,33 +196,53 @@ cask "pastebot" cask "postico" # HTTP client that helps testing and describing APIs cask "rapidapi" -# Move and resize windows using keyboard shortcuts or snap areas -cask "rectangle" +# Drag-and-drop Git history editor +cask "retcon" # Sound and audio controller cask "soundsource" +# Window and tab manager +cask "tabtab" +# Tool to automate the insertion of frequently used text and graphics +cask "typinator" # Open-source code editor cask "visual-studio-code" +# GPU-accelerated cross-platform terminal emulator and multiplexer +cask "wezterm" +# REST, GraphQL and gRPC client +cask "yaak" # Application for configuring any YubiKey cask "yubico-yubikey-manager" # Multiplayer code editor cask "zed" mas "1Password for Safari", id: 1569813296 +mas "Actions", id: 1586435171 +mas "Aiko", id: 1672085276 mas "Bear", id: 1091189122 mas "Boop", id: 1518425043 +mas "Color Picker", id: 1545870783 mas "com.kagimacOS.Kagi-Search", id: 1622835804 mas "Dato", id: 1470584107 +mas "GoodLinks", id: 1474335294 +mas "Hand Mirror", id: 1502839586 +mas "HEIC Converter", id: 1294126402 mas "Hush", id: 1544743900 mas "iA Writer", id: 775737590 mas "Microsoft To Do", id: 1274495053 mas "NepTunes", id: 1006739057 +mas "NotePlan", id: 1505432629 +mas "One Thing", id: 1604176982 +mas "Online Check", id: 6504709660 mas "Pixelmator Pro", id: 1289583905 mas "Play", id: 1596506190 -mas "Save to Reader", id: 1640236961 +mas "Shareful", id: 1522267256 +mas "Shortery", id: 1594183810 +mas "Sofa", id: 1276554886 +mas "Speediness", id: 1596706466 mas "TestFlight", id: 899247664 mas "Things", id: 904280696 mas "Trello", id: 1278508951 mas "Velja", id: 1607635845 -mas "Wipr", id: 1320666476 +mas "Wipr", id: 1662217862 mas "Xcode", id: 497799835 vscode "github.copilot" vscode "github.copilot-chat" diff --git a/nvim/lua/plugins/tokyonight.lua b/nvim/lua/plugins/tokyonight.lua index 59589ec89..14ac778bb 100644 --- a/nvim/lua/plugins/tokyonight.lua +++ b/nvim/lua/plugins/tokyonight.lua @@ -5,7 +5,7 @@ return { priority = 1000, -- make sure to load this before all the other start plugins config = function() -- load the colorscheme here - vim.cmd([[colorscheme tokyonight]]) + vim.cmd([[colorscheme tokyonight-night]]) end, }, } From fc4080b69564826322fbd8f16926a490cb1901a2 Mon Sep 17 00:00:00 2001 From: Dylan Pinn Date: Tue, 28 Jan 2025 13:40:16 +1100 Subject: [PATCH 13/13] WIP --- Makefile | 11 +++- ghostty/config | 3 + homebrew/work.Brewfile | 8 ++- nvim/after/ftplugin/lua.lua | 2 + nvim/init.lua | 7 ++ nvim/lua/config/lazy.lua | 6 -- nvim/lua/dcp/init.lua | 2 + nvim/lua/dcp/options.lua | 111 ++++++++++++++++++++++++++++++++ nvim/lua/dcp/set-background.lua | 15 +++++ nvim/lua/plugins/blink.lua | 58 ++++++++++++++--- nvim/lua/plugins/catppuccin.lua | 12 ++++ nvim/lua/plugins/conform.lua | 2 +- nvim/lua/plugins/fzf.lua | 24 +++++-- nvim/lua/plugins/lint.lua | 1 + nvim/lua/plugins/lsp.lua | 6 ++ nvim/lua/plugins/tokyonight.lua | 1 + 16 files changed, 244 insertions(+), 25 deletions(-) create mode 100644 ghostty/config create mode 100644 nvim/after/ftplugin/lua.lua create mode 100644 nvim/lua/dcp/init.lua create mode 100644 nvim/lua/dcp/options.lua create mode 100644 nvim/lua/dcp/set-background.lua create mode 100644 nvim/lua/plugins/catppuccin.lua diff --git a/Makefile b/Makefile index 812cea86b..e5d35086d 100644 --- a/Makefile +++ b/Makefile @@ -37,6 +37,11 @@ check-lua: check-prettier: npm run format:check +clean: clean-nvim + +clean-nvim: + rm -r -- $(XDG_CONFIG_HOME)/nvim + format: format-bash \ format-lua \ format-prettier \ @@ -67,8 +72,8 @@ dump-brew: install: install-bash \ install-bin \ - install-espanso \ install-git \ + install-ghostty \ install-mise \ install-npm \ install-nvim \ @@ -94,6 +99,10 @@ install-git: git/config cp -p -- git/config $(XDG_CONFIG_HOME)/git/config cp -p -- git/ignore $(XDG_CONFIG_HOME)/git/ignore +install-ghostty: + mkdir -p -- $(XDG_CONFIG_HOME)/ghostty + cp -p -- ghostty/config $(XDG_CONFIG_HOME)/ghostty/config + install-mise: install-bash cp -p -- mise/bashrc.d/* $(HOME)/.bashrc.d/ diff --git a/ghostty/config b/ghostty/config new file mode 100644 index 000000000..0f9093484 --- /dev/null +++ b/ghostty/config @@ -0,0 +1,3 @@ +font-family = JetBrainsMono Nerd Font Mono +theme = light:catppuccin-latte,dark:catppuccin-mocha +window-theme = auto diff --git a/homebrew/work.Brewfile b/homebrew/work.Brewfile index 9f876470f..f53147b87 100644 --- a/homebrew/work.Brewfile +++ b/homebrew/work.Brewfile @@ -74,7 +74,7 @@ brew "mas" # Polyglot runtime manager (asdf rust clone) brew "mise" # Ambitious Vim-fork focused on extensibility and agility -brew "neovim" +brew "neovim", args: ["HEAD"] # Search tool like grep and The Silver Searcher brew "ripgrep" # Safe, concurrent, practical language @@ -154,6 +154,8 @@ cask "font-roboto-mono" cask "font-source-code-pro" # GIT client cask "fork" +# Terminal emulator that uses platform-native UI and GPU acceleration +cask "ghostty" # Web browser cask "google-chrome" # Create presentation slides from a Markdown document @@ -196,6 +198,8 @@ cask "pastebot" cask "postico" # HTTP client that helps testing and describing APIs cask "rapidapi" +# Move and resize windows using keyboard shortcuts or snap areas +cask "rectangle" # Drag-and-drop Git history editor cask "retcon" # Sound and audio controller @@ -220,13 +224,13 @@ mas "Aiko", id: 1672085276 mas "Bear", id: 1091189122 mas "Boop", id: 1518425043 mas "Color Picker", id: 1545870783 -mas "com.kagimacOS.Kagi-Search", id: 1622835804 mas "Dato", id: 1470584107 mas "GoodLinks", id: 1474335294 mas "Hand Mirror", id: 1502839586 mas "HEIC Converter", id: 1294126402 mas "Hush", id: 1544743900 mas "iA Writer", id: 775737590 +mas "Kagi for Safari", id: 1622835804 mas "Microsoft To Do", id: 1274495053 mas "NepTunes", id: 1006739057 mas "NotePlan", id: 1505432629 diff --git a/nvim/after/ftplugin/lua.lua b/nvim/after/ftplugin/lua.lua new file mode 100644 index 000000000..685efe16d --- /dev/null +++ b/nvim/after/ftplugin/lua.lua @@ -0,0 +1,2 @@ +-- Tabs should have 4 space width. +vim.opt_local.tabstop = 4 diff --git a/nvim/init.lua b/nvim/init.lua index 55b8979f7..b9b81f601 100644 --- a/nvim/init.lua +++ b/nvim/init.lua @@ -1 +1,8 @@ +-- Make sure to setup `mapleader` and `maplocalleader` before +-- loading lazy.nvim so that mappings are correct. +-- This is also a good place to setup other settings (vim.opt) +vim.g.mapleader = " " +vim.g.maplocalleader = "\\" + require("config.lazy") +require("dcp") diff --git a/nvim/lua/config/lazy.lua b/nvim/lua/config/lazy.lua index c381a4b6b..0750c56bc 100644 --- a/nvim/lua/config/lazy.lua +++ b/nvim/lua/config/lazy.lua @@ -15,12 +15,6 @@ if not (vim.uv or vim.loop).fs_stat(lazypath) then end vim.opt.rtp:prepend(lazypath) --- Make sure to setup `mapleader` and `maplocalleader` before --- loading lazy.nvim so that mappings are correct. --- This is also a good place to setup other settings (vim.opt) -vim.g.mapleader = " " -vim.g.maplocalleader = "\\" - -- Setup lazy.nvim require("lazy").setup({ spec = { diff --git a/nvim/lua/dcp/init.lua b/nvim/lua/dcp/init.lua new file mode 100644 index 000000000..1eea5c002 --- /dev/null +++ b/nvim/lua/dcp/init.lua @@ -0,0 +1,2 @@ +require("dcp.options") +require("dcp.set-background") diff --git a/nvim/lua/dcp/options.lua b/nvim/lua/dcp/options.lua new file mode 100644 index 000000000..12a71c4b3 --- /dev/null +++ b/nvim/lua/dcp/options.lua @@ -0,0 +1,111 @@ +-- This file contains all of the options that are set using vim.opt.* expressions. The options in this file are sorted +-- alphabetically. +-- + +-- Enable automatic backups before overwriting a file and leave it around after the file has been written. These files +-- are kept in a cache directory by defualt in Neovim. +-- +vim.opt.backup = true + +-- By default Neovim will look to save backup files in the same directory as the file. It has a fallback to a cache +-- directory so removing the first option will use that instead. +-- +vim.opt.backupdir:remove({ "." }) + +-- When wrapping a line, if that line is indented then the wrapped line is also indented the same amount. +-- +vim.opt.breakindent = true + +-- Neovim includes defaults for comments that date back to its history as a mainly C development environment. Removing +-- these values allows us to use filetype plugins to set them as needed. +-- +vim.opt.comments = "" + +-- Use two spaces to end a sentence. This helps improve readability using monospaced fonts. This also helps vim work +-- with sentence objects for the purpose of the 's' text objects, the '(' and ')' sentence motions, and formatting with +-- the 'gq' command must now be separated by two spaces. +-- +-- See https://stevelosh.com/blog/2012/10/why-i-two-space/ +-- +vim.opt.cpoptions:append("J") + +-- Neovim's defaults for macro definitions, which are used for include-search, defaults that also date back to its +-- history as a mainly C development environment. Removing these values allows ut to use filetype plugins to set them as +-- needed. +-- +vim.opt.define = "" +-- +-- Automatic text wrapping options using flags in the 'formatoptions' option begin here. + +-- Don't break a line after a one-letter word like "I" or "a". +-- +vim.opt.formatoptions:append({ 1 }) + +-- Because we are using two spaces for ending sentences. Vim can determine if the space after an abbreviation such as +-- "Mr. Pinn" is the end of the sentence or not and then determine if it should be split on it. The 'p' flag makes this +-- possible. +-- +vim.opt.formatoptions:append({ "p" }) + +-- Ignore case when searching. +-- +vim.opt.ignorecase = true + +-- Neovim's defaults for finding include commands, defaults that also date back to its history as a mainly C development +-- environment. Removing these values allows ut to use filetype plugins to set them as needed. +-- +vim.opt.include = "" +-- +-- When soft-wraps are enabled with 'wrap' option, then break the line between words, rather than within them. +-- +vim.opt.linebreak = true + +-- Neovim includes defaults for path that date back to its history as a mainly C development environment. Removing +-- these values allows us to use filetype plugins to set them as needed. +-- +vim.opt.path:remove({ "/usr/include" }) + +-- When wrapping a line using soft-wraps, highlight that it has been wrapped by inserting a leading string - "> ". +-- +vim.opt.showbreak = "> " + +-- Becuase we are ignoring case when searching, if the search contains upper-case characters then use that rather than +-- ignoring it. +-- +vim.opt.smartcase = true + +-- Use basic statusline, using this rather than an external plugin to do this as this currently fits my needs and +-- doesn't add extra complexity. +-- +-- Taken from https://www.vi-improved.org/recommendations/ +-- +vim.opt.statusline = "%F%m%r%h%w[%L][%{&ff}]%y[%p%%][%04l,%04v]" +-- | | | | | | | | | | | +-- | | | | | | | | | | +-- current column +-- | | | | | | | | | +-- current line +-- | | | | | | | | +-- current % into file +-- | | | | | | | +-- current syntax +-- | | | | | | +-- current fileformat +-- | | | | | +-- number of lines +-- | | | | +-- preview flag in square brackets +-- | | | +-- help flag in square brackets +-- | | +-- readonly flag in square brackets +-- | +-- rodified flag in square brackets +-- +-- full path to file in the buffer + +-- Keep track of undo history for files between sessions. This ensures that undo and redo are available between Vim +-- invocations. These files are kept in a cache directory. +-- +vim.opt.undofile = true + +-- Configure the wildmenu to ignore a list of patterns for file and directory command line completion. Files and +-- directories matching any of these patterns won't be presented as candidates for tab completion on the command line. +-- +-- The list combines a mixture of binary files that would not contain text and therefore would not want to edit, and +-- directories that contain generated files that won't want to be edited either. +-- +vim.opt.wildignore:append({ "*/node_modules/*" }) -- ignore dependency directories. + +-- Configure wildmenu to show the full list of matches while also completing the first full match. +-- +vim.opt.wildmode = "list:full" diff --git a/nvim/lua/dcp/set-background.lua b/nvim/lua/dcp/set-background.lua new file mode 100644 index 000000000..595d00109 --- /dev/null +++ b/nvim/lua/dcp/set-background.lua @@ -0,0 +1,15 @@ +-- Set 'background' option based on on $TERMCS. + +local termcs = os.getenv("TERMCS") or "dark" +local function set_bg() + if termcs == "dark" then + vim.api.nvim_set_option_value("background", "dark", {}) + vim.cmd("colorscheme catppuccin-mocha") + else + vim.api.nvim_set_option_value("background", "light", {}) + vim.cmd("colorscheme catppuccin-latte") + end +end + +vim.api.nvim_create_user_command("SetBG", set_bg, {}) +vim.cmd.SetBG() diff --git a/nvim/lua/plugins/blink.lua b/nvim/lua/plugins/blink.lua index e96673a42..7b2d58f59 100644 --- a/nvim/lua/plugins/blink.lua +++ b/nvim/lua/plugins/blink.lua @@ -5,24 +5,64 @@ return { dependencies = "rafamadriz/friendly-snippets", -- use a release tag to download pre-built binaries - version = "v0.*", + version = "*", + + ---@module 'blink.cmp' + ---@type blink.cmp.Config opts = { - keymap = { preset = "default" }, + -- 'default' for mappings similar to built-in completion + -- 'super-tab' for mappings similar to vscode (tab to accept, arrow keys to navigate) + -- 'enter' for mappings similar to 'super-tab' but with 'enter' to accept + -- See the full "keymap" documentation for information on defining your own keymap. + keymap = { + preset = "default", + cmdline = { + preset = "enter", + }, + }, appearance = { + -- Sets the fallback highlight groups to nvim-cmp's highlight groups + -- Useful for when your theme doesn't support blink.cmp + -- Will be removed in a future release use_nvim_cmp_as_default = true, + -- Set to 'mono' for 'Nerd Font Mono' or 'normal' for 'Nerd Font' + -- Adjusts spacing to ensure icons are aligned nerd_font_variant = "mono", }, + -- Default list of enabled providers defined so that you can extend it + -- elsewhere in your config, without redefining it, due to `opts_extend` sources = { - default = { "lsp", "path", "snippets", "buffer", "lazydev" }, + default = { "lazydev", "lsp", "path", "snippets", "buffer" }, + cmdline = function() + -- local type = vim.fn.getcmdtype() + -- -- Search forward and backward. + -- if type == "/" or type == "?" then + -- return { "buffer" } + -- end + -- -- Commands + -- if type == ":" then + -- return { "cmdline" } + -- end + return {} + end, + providers = { + lazydev = { + name = "LazyDev", + module = "lazydev.integrations.blink", + -- make lazydev completions top priority (see `:h blink.cmp`) + score_offset = 100, + }, + }, }, - providers = { - -- dont show LuaLS require statements when lazydev has items - lsp = { fallback_for = { "lazydev" } }, - lazydev = { name = "LazyDev", module = "lazydev.integrations.blink" }, - }, - + -- completion = { + -- menu = { + -- auto_show = function(ctx) + -- return ctx.mode ~= "cmdline" or not vim.tbl_contains({ "/", "?" }, vim.fn.getcmdtype()) + -- end, + -- }, + -- }, signature = { enabled = true }, }, opts_extend = { "sources.default" }, diff --git a/nvim/lua/plugins/catppuccin.lua b/nvim/lua/plugins/catppuccin.lua new file mode 100644 index 000000000..e9ca90f4a --- /dev/null +++ b/nvim/lua/plugins/catppuccin.lua @@ -0,0 +1,12 @@ +return { + { + "catppuccin/nvim", + name = "catppuccin", + lazy = false, -- make sure we load this during startup if it is your main colorscheme + priority = 1000, -- make sure to load this before all the other start plugins + config = function() + -- load the colorscheme here + vim.cmd([[colorscheme catppuccin-latte]]) + end, + }, +} diff --git a/nvim/lua/plugins/conform.lua b/nvim/lua/plugins/conform.lua index 9dbdf4e46..7cbdc5f3b 100644 --- a/nvim/lua/plugins/conform.lua +++ b/nvim/lua/plugins/conform.lua @@ -7,7 +7,7 @@ return { opts = { formatters_by_ft = { lua = { "stylua" }, - -- typescript = { { "prettierd", "prettier" }, "eslint_d" }, + typescript = { { "prettierd", "prettier" }, "eslint_d" }, }, format_on_save = { -- These options will be passed to conform.format() diff --git a/nvim/lua/plugins/fzf.lua b/nvim/lua/plugins/fzf.lua index 04f5da14f..ffcd8fb4e 100644 --- a/nvim/lua/plugins/fzf.lua +++ b/nvim/lua/plugins/fzf.lua @@ -3,17 +3,29 @@ return { "ibhagwan/fzf-lua", cmd = "FzfLua", -- lazy load when invoked. -- optional for icon support - dependencies = { "nvim-tree/nvim-web-devicons" }, + dependencies = { "nvim-tree/nvim-web-devicons", "MeanderingProgrammer/render-markdown.nvim" }, config = function() -- calling `setup` is optional for customization require("fzf-lua").setup({}) end, keys = { - { "", "FzfLua files" }, - { "/", "FzfLua live_grep" }, - { ":", "FzfLua command_history" }, - { "/", "FzfLua buffers" }, - { "", "FzfLua helptags" }, + { "", "FzfLua files" }, -- find or fd on a path. + { "/", "FzfLua live_grep" }, -- live grep current project. + { ":", "FzfLua command_history" }, -- command history. + { "b", "FzfLua buffers" }, -- open buffers. + { "", "FzfLua helptags" }, -- help tags. + + { "", "FzfLua buffers" }, -- open buffers. + { "", "FzfLua builtin" }, -- fzf-lua builtin commands + { "", "FzfLua files" }, -- find or fd on a path. + { "", "FzfLua live_grep_glob" }, -- live_grep with rg --glob support. + { "", "FzfLua grep_project" }, -- search all project files. + -- vim.api.nvim_set_keymap("n", "", [[lua require"fzf-lua".buffers()]], {}) + -- vim.api.nvim_set_keymap("n", "", [[lua require"fzf-lua".builtin()]], {}) + -- vim.api.nvim_set_keymap("n", "", [[lua require"fzf-lua".files()]], {}) + -- vim.api.nvim_set_keymap("n", "", [[lua require"fzf-lua".live_grep_glob()]], {}) + -- vim.api.nvim_set_keymap("n", "", [[lua require"fzf-lua".grep_project()]], {}) + -- vim.api.nvim_set_keymap("n", "", [[lua require"fzf-lua".help_tags()]], {}) }, }, } diff --git a/nvim/lua/plugins/lint.lua b/nvim/lua/plugins/lint.lua index 065b1ea86..7549cab4a 100644 --- a/nvim/lua/plugins/lint.lua +++ b/nvim/lua/plugins/lint.lua @@ -11,6 +11,7 @@ return { config = function() require("lint").linters_by_ft = { lua = { "luacheck" }, + typescript = { "eslint" }, } end, }, diff --git a/nvim/lua/plugins/lsp.lua b/nvim/lua/plugins/lsp.lua index 63bc6a99a..206bbfe3f 100644 --- a/nvim/lua/plugins/lsp.lua +++ b/nvim/lua/plugins/lsp.lua @@ -54,6 +54,7 @@ return { end, config = function() local lspconfig = require("lspconfig") + local capabilities = require("blink.cmp").get_lsp_capabilities() lspconfig.lua_ls.setup({ on_init = function(client) @@ -98,6 +99,11 @@ return { }, }, }, + capabilities = capabilities, + }) + + lspconfig.ts_ls.setup({ + capabilities = capabilities, }) end, }, diff --git a/nvim/lua/plugins/tokyonight.lua b/nvim/lua/plugins/tokyonight.lua index 14ac778bb..fdf48736a 100644 --- a/nvim/lua/plugins/tokyonight.lua +++ b/nvim/lua/plugins/tokyonight.lua @@ -7,5 +7,6 @@ return { -- load the colorscheme here vim.cmd([[colorscheme tokyonight-night]]) end, + enable = false, }, }