diff --git a/doc/smoketest.md b/doc/smoketest.md new file mode 100644 index 00000000..6f0d3ef3 --- /dev/null +++ b/doc/smoketest.md @@ -0,0 +1,60 @@ +# Smoketest + +A manual smoketest checklist to ensure features are working: + +## Plugins +### Default +- [ ] Whichkey should have accurate keybindings + - g -> [G]it + - n -> [N]otepad + - s -> [S]earch + - t -> [T]oggle + +### Kickstart +Kickstart plugins *that are enabled* should be working +- [ ] Autopairs + - Brackets, parenthesis, etc, should automatically close +- [ ] IndentLine + - Should see visual indentation guides for indented lines + +### Custom +Custom plugins should be working +- [ ] Oil + - Shortcut `-` should open Oil +- [ ] Snacks + - Should load dashboard at start, and `=` should open dashboard + - `gb` should open the remote git repository in a browser + - `gl` should open lazy git + - `no` should open a scratchpad + - `ns` browses existing notes in scratchpad + - `` should open a terminal +- [ ] VimTmuxNavigator + - Should be able to navigate between nvim and tmux panes using ``, ``, ``, `` for each respective direction +- [ ] Remote SSHFS + - Should be able to remotely access a directory using the `:RemoteSSHFSConnect` command +- [ ] Guttermarks + - Marks (place a mark with `m`) should be displayed in the gutter by their character + +### Themes +- [ ] Catppuccin Theme +- [ ] Rose Pine Theme + +## Settings +- [ ] Nerd fonts should be enabled +- [ ] Line numbers should be relative +- [ ] Virtual Diagnostic Lines (errors/warnings) should be beneath the applicable line +- [ ] Arrow key navigation should be disabled +- [ ] Should connect to godot server when running + +## LSP + +- [ ] LSP, autocomplete, and formatting should work for the following file types + - Javascript `.js`, `.jsx` + - Typescript `.ts`, `.tsx` + - Svelte `.svelte` + - C# `.cs` + - Lua `.lua` +- [ ] Mason should ensure that the following tools are installed + - Clangd + - Pyright + - Omnisharp diff --git a/init.lua b/init.lua index 8719106c..ae53f036 100644 --- a/init.lua +++ b/init.lua @@ -194,8 +194,8 @@ do underline = { severity = { min = vim.diagnostic.severity.WARN } }, -- Can switch between these as you prefer - virtual_text = true, -- Text shows up at the end of the line - virtual_lines = false, -- Text shows up underneath the line, with virtual lines + virtual_text = false, -- Text shows up at the end of the line + virtual_lines = true, -- Text shows up underneath the line, with virtual lines -- Auto open the float, so you can easily read the errors when jumping with `[d` and `]d` jump = { @@ -220,10 +220,10 @@ do vim.keymap.set('t', '', '', { desc = 'Exit terminal mode' }) -- TIP: Disable arrow keys in normal mode - -- vim.keymap.set('n', '', 'echo "Use h to move!!"') - -- vim.keymap.set('n', '', 'echo "Use l to move!!"') - -- vim.keymap.set('n', '', 'echo "Use k to move!!"') - -- vim.keymap.set('n', '', 'echo "Use j to move!!"') + vim.keymap.set('n', '', 'echo "Use h to move!!"') + vim.keymap.set('n', '', 'echo "Use l to move!!"') + vim.keymap.set('n', '', 'echo "Use k to move!!"') + vim.keymap.set('n', '', 'echo "Use j to move!!"') -- Keybinds to make split navigation easier. -- Use CTRL+ to switch between windows @@ -372,7 +372,10 @@ do { 's', group = '[S]earch', mode = { 'n', 'v' } }, { 't', group = '[T]oggle' }, { 'h', group = 'Git [H]unk', mode = { 'n', 'v' } }, -- Enable gitsigns recommended keymaps first + -- TODO: LSP actions (anything with `gr`) should be with the leader key { 'gr', group = 'LSP Actions', mode = { 'n' } }, + { 'g', group = '[G]it' }, + { 'n', group = '[N]otepad' }, }, } @@ -390,6 +393,9 @@ do }, } + vim.pack.add { gh 'catppuccin/nvim' } + vim.pack.add { gh 'rose-pine/neovim' } + -- Load the colorscheme here. -- Like many other themes, this one has different styles, and you could load -- any other, such as 'tokyonight-storm', 'tokyonight-moon', or 'tokyonight-day'. @@ -416,6 +422,7 @@ do -- - va) - [V]isually select [A]round [)]paren -- - yiiq - [Y]ank [I]nside [I]+1 [Q]uote -- - ci' - [C]hange [I]nside [']quote + --FIX: mini.ai does not seem to be working correctly. Conflicts? require('mini.ai').setup { -- NOTE: Avoid conflicts with the built-in incremental selection mappings on Neovim>=0.12 (see `:help treesitter-incremental-selection`) mappings = { @@ -430,6 +437,7 @@ do -- - saiw) - [S]urround [A]dd [I]nner [W]ord [)]Paren -- - sd' - [S]urround [D]elete [']quotes -- - sr)' - [S]urround [R]eplace [)] ['] + --FIX: mini.surround does not seem to be working correctly. Conflicts? require('mini.surround').setup() -- Simple and easy statusline. @@ -693,9 +701,9 @@ do -- See `:help lsp-config` for information about keys and how to configure ---@type table local servers = { - -- clangd = {}, + clangd = {}, -- gopls = {}, - -- pyright = {}, + pyright = {}, -- rust_analyzer = {}, -- -- Some languages (like typescript) have entire language plugins that can be useful: @@ -704,6 +712,8 @@ do -- But for many setups, the LSP (`ts_ls`) will work just fine -- ts_ls = {}, + omnisharp = {}, -- Used to format C# code + stylua = {}, -- Used to format Lua code -- Special Lua Config, as recommended by neovim help docs @@ -761,6 +771,9 @@ do local ensure_installed = vim.tbl_keys(servers or {}) vim.list_extend(ensure_installed, { -- You can add other tools here that you want Mason to install + 'clangd', + 'pyright', + 'omnisharp', }) require('mason-tool-installer').setup { ensure_installed = ensure_installed } diff --git a/lua/custom/plugins/guttermarks.lua b/lua/custom/plugins/guttermarks.lua index fbc79a63..8fa1d3d6 100644 --- a/lua/custom/plugins/guttermarks.lua +++ b/lua/custom/plugins/guttermarks.lua @@ -1,4 +1 @@ -return { - 'dimtion/guttermarks.nvim', - event = { 'BufReadPost', 'BufNewFile', 'BufWritePre', 'FileType' }, -} +vim.pack.add { "https://github.com/dimtion/guttermarks.nvim" } diff --git a/lua/custom/plugins/mini.lua b/lua/custom/plugins/mini.lua index bea310ba..061127a8 100644 --- a/lua/custom/plugins/mini.lua +++ b/lua/custom/plugins/mini.lua @@ -1,32 +1,9 @@ -return { - 'nvim-mini/mini.nvim', - config = function() - -- Better Around/Inside textobjects - -- - -- Examples: - -- - va) - [V]isually select [A]round [)]paren - -- - yinq - [Y]ank [I]nside [N]ext [Q]uote - -- - ci' - [C]hange [I]nside [']quote - require('mini.ai').setup { n_lines = 500 } +require('mini.git').setup() - -- Add/delete/replace surroundings (brackets, quotes, etc.) - -- - -- - saiw) - [S]urround [A]dd [I]nner [W]ord [)]Paren - -- - sd' - [S]urround [D]elete [']quotes - -- - sr)' - [S]urround [R]eplace [)] ['] - require('mini.surround').setup() +vim.keymap.set('n', 'ga', 'Git add -A', { desc = 'Git add all' }) +vim.keymap.set('n', 'gc', 'Git commit', { desc = 'Git commit' }) +vim.keymap.set('n', 'gs', 'Git status', { desc = 'Git status' }) +vim.keymap.set('n', 'gg', 'Git log --graph --oneline --all', { desc = 'Git graph' }) - require('mini.move').setup() - require('mini.git').setup() - - local statusline = require 'mini.statusline' - statusline.setup { use_icons = vim.g.have_nerd_font } - ---@diagnostic disable-next-line: duplicate-set-field - statusline.section_location = function() return '%2l:%-2v' end - - vim.keymap.set('n', 'ga', 'Git add -A', { desc = 'Git add all' }) - vim.keymap.set('n', 'gc', 'Git commit', { desc = 'Git commit' }) - vim.keymap.set('n', 'gs', 'Git status', { desc = 'Git status' }) - vim.keymap.set('n', 'gg', 'Git log --graph --oneline --all', { desc = 'Git graph' }) - end, -} +require('mini.move').setup() +-- usage: Alt = directional keys should move the line in normal mode diff --git a/lua/custom/plugins/oil.lua b/lua/custom/plugins/oil.lua index 66018eb6..016895d2 100644 --- a/lua/custom/plugins/oil.lua +++ b/lua/custom/plugins/oil.lua @@ -1,7 +1,4 @@ -return { - 'stevearc/oil.nvim', - config = function() - require('oil').setup() - vim.keymap.set('n', '-', 'Oil', { desc = 'Open parent directory' }) - end, +vim.pack.add { 'https://github.com/stevearc/oil.nvim' } +require('oil').setup { + vim.keymap.set('n', '-', 'Oil', { desc = 'Open parent directory' }), } diff --git a/lua/custom/plugins/remote-sshfs.lua b/lua/custom/plugins/remote-sshfs.lua index dda4fd04..60abac3c 100644 --- a/lua/custom/plugins/remote-sshfs.lua +++ b/lua/custom/plugins/remote-sshfs.lua @@ -1,8 +1,5 @@ -return { - 'nosduco/remote-sshfs.nvim', - dependencies = { 'nvim-telescope/telescope.nvim', 'nvim-lua/plenary.nvim' }, - opts = {}, -} +vim.pack.add { "https://github.com/nosduco/remote-sshfs.nvim"} +require('remote-sshfs').setup() -- Usage: :RemoteSSHFSConnect @:/path/to/file -- Sometimes you have to force close, and that causes permission failed on reconnect. diff --git a/lua/custom/plugins/snacks.lua b/lua/custom/plugins/snacks.lua index 8144c975..82944056 100644 --- a/lua/custom/plugins/snacks.lua +++ b/lua/custom/plugins/snacks.lua @@ -1,24 +1,23 @@ -return { - 'folke/snacks.nvim', - priority = 1000, - lazy = false, - ---@type snacks.Config - opts = { - --TODO: Use this for a bit and compare to mini dashboard - --TODO: design a style and featuers for my dashboard (add opening parent directory with Oil) - dashboard = { enabled = true }, - gitbrowse = { enabled = true }, - lazygit = { enabled = true }, - --TODO: determine a method for deleting scratches easily - scratch = { enabled = true }, - terminal = { enabled = true }, - }, - keys = { - { '=', function() Snacks.dashboard.open() end, desc = 'Dashboard' }, - { 'gb', function() Snacks.gitbrowse.open() end, desc = 'Open Git Repository in Browser' }, - { 'gl', function() Snacks.lazygit.open() end, desc = 'Open Lazy Git' }, - { 'no', function() Snacks.scratch() end, desc = 'Open Notepad' }, - { 'ns', function() Snacks.scratch.select() end, desc = 'Select Note' }, - { '', function() Snacks.terminal() end, desc = 'Open Terminal' }, +--TODO: design a style and features for my dashboard (add opening parent directory with Oil) +--TODO: determine a method for deleting scratches easily +vim.pack.add { 'https://github.com/folke/snacks.nvim' } +require('snacks').setup { + dashboard = { + enabled = true, + sections = { + { section = 'header' }, + { section = 'keys', gap = 1, padding = 1 }, + }, }, + gitbrowse = { enabled = true }, + lazygit = { enabled = true }, + scratch = { enabled = true }, + terminal = { enabled = true }, } + +vim.keymap.set('n', '=', function() Snacks.dashboard.open() end, { desc = 'Dashboard' }) +vim.keymap.set('n', 'gb', function() Snacks.gitbrowse.open() end, { desc = 'Open [G]it Repository in [B]rowser' }) +vim.keymap.set('n', 'gl', function() Snacks.lazygit.open() end, { desc = 'Open [L]azy [G]it' }) +vim.keymap.set('n', 'no', function() Snacks.scratch() end, { desc = '[O]pen [N]otepad' }) +vim.keymap.set('n', 'ns', function() Snacks.scratch.select() end, { desc = '[S]elect [N]ote' }) +vim.keymap.set('n', '', function() Snacks.terminal() end, { desc = 'Open [T]erminal' }) diff --git a/lua/custom/plugins/typescript-tools.lua b/lua/custom/plugins/typescript-tools.lua index ba7fb204..f35d3fdb 100644 --- a/lua/custom/plugins/typescript-tools.lua +++ b/lua/custom/plugins/typescript-tools.lua @@ -1,5 +1,2 @@ -return { - 'pmizio/typescript-tools.nvim', - dependencies = { 'nvim-lua/plenary.nvim', 'neovim/nvim-lspconfig' }, - opts = {}, -} +vim.pack.add { 'https://github.com/pmizio/typescript-tools.nvim' } +require('typescript-tools').setup {} diff --git a/lua/custom/plugins/vimtmuxnavigator.lua b/lua/custom/plugins/vimtmuxnavigator.lua index d4aaccb2..c4e21b1b 100644 --- a/lua/custom/plugins/vimtmuxnavigator.lua +++ b/lua/custom/plugins/vimtmuxnavigator.lua @@ -1,3 +1 @@ -return { - 'christoomey/vim-tmux-navigator', -} +vim.pack.add { 'https://github.com/christoomey/vim-tmux-navigator' }