diff --git a/README.md b/README.md
index f445b65e..5ca19d7a 100644
--- a/README.md
+++ b/README.md
@@ -24,7 +24,6 @@ If you are experiencing issues, please make sure you have the latest versions.
External Requirements:
- Basic utils: `git`, `make`, `unzip`, C Compiler (`gcc`)
- [ripgrep](https://github.com/BurntSushi/ripgrep#installation)
-- Clipboard tool (xclip/xsel/win32yank or other depending on platform)
- A [Nerd Font](https://www.nerdfonts.com/): optional, provides various icons
- if you have it set `vim.g.have_nerd_font` in `init.lua` to true
- Language Setup:
@@ -100,10 +99,71 @@ That's it! Lazy will install all the plugins you have. Use `:Lazy` to view
current plugin status. Hit `q` to close the window.
Read through the `init.lua` file in your configuration folder for more
-information about extending and exploring Neovim. That also includes
-examples of adding popularly requested plugins.
+information about extending and exploring Neovim.
+#### Examples of adding popularly requested plugins
+
+NOTE: You'll need to uncomment the line in the init.lua that turns on loading custom plugins.
+
+
+ Adding autopairs
+
+This will automatically install [windwp/nvim-autopairs](https://github.com/windwp/nvim-autopairs)
+and enable it on startup. For more information, see documentation for
+[lazy.nvim](https://github.com/folke/lazy.nvim).
+
+In the file: `lua/custom/plugins/autopairs.lua`, add:
+
+```lua
+-- File: lua/custom/plugins/autopairs.lua
+
+return {
+ "windwp/nvim-autopairs",
+ -- Optional dependency
+ dependencies = { 'hrsh7th/nvim-cmp' },
+ config = function()
+ require("nvim-autopairs").setup {}
+ -- If you want to automatically add `(` after selecting a function or method
+ local cmp_autopairs = require('nvim-autopairs.completion.cmp')
+ local cmp = require('cmp')
+ cmp.event:on(
+ 'confirm_done',
+ cmp_autopairs.on_confirm_done()
+ )
+ end,
+}
+```
+
+
+
+ Adding a file tree plugin
+
+This will install the tree plugin and add the command `:Neotree` for you.
+For more information, see the documentation at
+[neo-tree.nvim](https://github.com/nvim-neo-tree/neo-tree.nvim).
+
+In the file: `lua/custom/plugins/filetree.lua`, add:
+
+```lua
+-- File: lua/custom/plugins/filetree.lua
+
+return {
+ "nvim-neo-tree/neo-tree.nvim",
+ version = "*",
+ dependencies = {
+ "nvim-lua/plenary.nvim",
+ "nvim-tree/nvim-web-devicons", -- not strictly required, but recommended
+ "MunifTanjim/nui.nvim",
+ },
+ config = function ()
+ require('neo-tree').setup {}
+ end,
+}
+```
+
+
+
### Getting Started
[The Only Video You Need to Get Started with Neovim](https://youtu.be/m8C0Cq9Uv9o)
@@ -183,7 +243,7 @@ wsl --install
wsl
sudo add-apt-repository ppa:neovim-ppa/unstable -y
sudo apt update
-sudo apt install make gcc ripgrep unzip git xclip neovim
+sudo apt install make gcc ripgrep unzip neovim
```
@@ -193,37 +253,23 @@ sudo apt install make gcc ripgrep unzip git xclip neovim
```
sudo add-apt-repository ppa:neovim-ppa/unstable -y
sudo apt update
-sudo apt install make gcc ripgrep unzip git xclip neovim
+sudo apt install make gcc ripgrep unzip neovim
```
Debian Install Steps
```
sudo apt update
-sudo apt install make gcc ripgrep unzip git xclip curl
-
-# Now we install nvim
-curl -LO https://github.com/neovim/neovim/releases/latest/download/nvim-linux64.tar.gz
-sudo rm -rf /opt/nvim-linux64
-sudo mkdir -p /opt/nvim-linux64
-sudo chmod a+rX /opt/nvim-linux64
-sudo tar -C /opt -xzf nvim-linux64.tar.gz
-
-# make it available in /usr/local/bin, distro installs to /usr/bin
-sudo ln -sf /opt/nvim-linux64/bin/nvim /usr/local/bin/
+sudo apt install make gcc ripgrep unzip git
+echo "deb https://deb.debian.org/debian unstable main" | sudo tee -a /etc/apt/sources.list
+sudo apt update
+sudo apt install -t unstable neovim
```
Fedora Install Steps
```
-sudo dnf install -y gcc make git ripgrep fd-find unzip neovim
-```
-
-
-Arch Install Steps
-
-```
-sudo pacman -S --noconfirm --needed gcc make git ripgrep fd unzip neovim
+sudo dnf install -y gcc make git ripgrep fd-find neovim
```
diff --git a/init.lua b/init.lua
index 88658ef3..0849c723 100644
--- a/init.lua
+++ b/init.lua
@@ -90,7 +90,7 @@ P.S. You can delete this when you're done too. It's your config now! :)
vim.g.mapleader = ' '
vim.g.maplocalleader = ' '
--- Set to true if you have a Nerd Font installed and selected in the terminal
+-- Set to true if you have a Nerd Font installed
vim.g.have_nerd_font = false
-- [[ Setting options ]]
@@ -286,13 +286,7 @@ require('lazy').setup({
['r'] = { name = '[R]ename', _ = 'which_key_ignore' },
['s'] = { name = '[S]earch', _ = 'which_key_ignore' },
['w'] = { name = '[W]orkspace', _ = 'which_key_ignore' },
- ['t'] = { name = '[T]oggle', _ = 'which_key_ignore' },
- ['h'] = { name = 'Git [H]unk', _ = 'which_key_ignore' },
}
- -- visual mode
- require('which-key').register({
- ['h'] = { 'Git [H]unk' },
- }, { mode = 'v' })
end,
},
@@ -412,7 +406,7 @@ require('lazy').setup({
'neovim/nvim-lspconfig',
dependencies = {
-- Automatically install LSPs and related tools to stdpath for Neovim
- { 'williamboman/mason.nvim', config = true }, -- NOTE: Must be loaded before dependants
+ 'williamboman/mason.nvim',
'williamboman/mason-lspconfig.nvim',
'WhoIsSethDaniel/mason-tool-installer.nvim',
@@ -514,36 +508,15 @@ require('lazy').setup({
-- When you move your cursor, the highlights will be cleared (the second autocommand).
local client = vim.lsp.get_client_by_id(event.data.client_id)
if client and client.server_capabilities.documentHighlightProvider then
- local highlight_augroup = vim.api.nvim_create_augroup('kickstart-lsp-highlight', { clear = false })
vim.api.nvim_create_autocmd({ 'CursorHold', 'CursorHoldI' }, {
buffer = event.buf,
- group = highlight_augroup,
callback = vim.lsp.buf.document_highlight,
})
vim.api.nvim_create_autocmd({ 'CursorMoved', 'CursorMovedI' }, {
buffer = event.buf,
- group = highlight_augroup,
callback = vim.lsp.buf.clear_references,
})
-
- vim.api.nvim_create_autocmd('LspDetach', {
- group = vim.api.nvim_create_augroup('kickstart-lsp-detach', { clear = true }),
- callback = function(event2)
- vim.lsp.buf.clear_references()
- vim.api.nvim_clear_autocmds { group = 'kickstart-lsp-highlight', buffer = event2.buf }
- end,
- })
- end
-
- -- The following autocommand is used to enable inlay hints in your
- -- code, if the language server you are using supports them
- --
- -- This may be unwanted, since they displace some of your code
- if client and client.server_capabilities.inlayHintProvider and vim.lsp.inlay_hint then
- map('th', function()
- vim.lsp.inlay_hint.enable(not vim.lsp.inlay_hint.is_enabled())
- end, '[T]oggle Inlay [H]ints')
end
end,
})
@@ -731,12 +704,6 @@ require('lazy').setup({
-- This will expand snippets if the LSP sent a snippet.
[''] = cmp.mapping.confirm { select = true },
- -- If you prefer more traditional completion keymaps,
- -- you can uncomment the following lines
- --[''] = cmp.mapping.confirm { select = true },
- --[''] = cmp.mapping.select_next_item(),
- --[''] = cmp.mapping.select_prev_item(),
-
-- Manually trigger a completion from nvim-cmp.
-- Generally you don't need this, because nvim-cmp will display
-- completions whenever it has completion options available.
@@ -773,24 +740,52 @@ require('lazy').setup({
end,
},
- { -- You can easily change to a different colorscheme.
- -- Change the name of the colorscheme plugin below, and then
- -- change the command in the config to whatever the name of that colorscheme is.
- --
- -- If you want to see what colorschemes are already installed, you can use `:Telescope colorscheme`.
- 'folke/tokyonight.nvim',
- priority = 1000, -- Make sure to load this before all the other start plugins.
- init = function()
- -- 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'.
- vim.cmd.colorscheme 'tokyonight-night'
-
- -- You can configure highlights by doing something like:
- vim.cmd.hi 'Comment gui=none'
+ {
+ -- Theme inspired by Atom
+ 'navarasu/onedark.nvim',
+ priority = 1000,
+ lazy = false,
+ config = function()
+ require('onedark').setup {
+ -- Set a style preset. 'dark' is default.
+ style = 'darker', -- dark, darker, cool, deep, warm, warmer, light
+ }
+ require('onedark').load()
end,
},
+ {
+ -- Set lualine as statusline
+ 'nvim-lualine/lualine.nvim',
+ -- See `:help lualine.txt`
+ opts = {
+ options = {
+ icons_enabled = false,
+ theme = 'onedark',
+ component_separators = '|',
+ section_separators = '',
+ },
+ },
+ },
+
+ -- { -- You can easily change to a different colorscheme.
+ -- -- Change the name of the colorscheme plugin below, and then
+ -- -- change the command in the config to whatever the name of that colorscheme is.
+ -- --
+ -- -- If you want to see what colorschemes are already installed, you can use `:Telescope colorscheme`.
+ -- 'folke/tokyonight.nvim',
+ -- priority = 1000, -- Make sure to load this before all the other start plugins.
+ -- init = function()
+ -- -- 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'.
+ -- vim.cmd.colorscheme 'tokyonight-night'
+ --
+ -- -- You can configure highlights by doing something like:
+ -- vim.cmd.hi 'Comment gui=none'
+ -- end,
+ -- },
+ --
-- Highlight todo, notes, etc in comments
{ 'folke/todo-comments.nvim', event = 'VimEnter', dependencies = { 'nvim-lua/plenary.nvim' }, opts = { signs = false } },
@@ -829,13 +824,14 @@ require('lazy').setup({
-- ... and there is more!
-- Check out: https://github.com/echasnovski/mini.nvim
+ require('mini.pairs').setup()
end,
},
{ -- Highlight, edit, and navigate code
'nvim-treesitter/nvim-treesitter',
build = ':TSUpdate',
opts = {
- ensure_installed = { 'bash', 'c', 'diff', 'html', 'lua', 'luadoc', 'markdown', 'vim', 'vimdoc' },
+ ensure_installed = { 'bash', 'c', 'html', 'lua', 'luadoc', 'markdown', 'vim', 'vimdoc' },
-- Autoinstall languages that are not installed
auto_install = true,
highlight = {
@@ -850,8 +846,6 @@ require('lazy').setup({
config = function(_, opts)
-- [[ Configure Treesitter ]] See `:help nvim-treesitter`
- -- Prefer git instead of curl in order to improve connectivity in some environments
- require('nvim-treesitter.install').prefer_git = true
---@diagnostic disable-next-line: missing-fields
require('nvim-treesitter.configs').setup(opts)
@@ -873,12 +867,9 @@ require('lazy').setup({
-- Here are some example plugins that I've included in the Kickstart repository.
-- Uncomment any of the lines below to enable them (you will need to restart nvim).
--
- -- require 'kickstart.plugins.debug',
- -- require 'kickstart.plugins.indent_line',
- -- require 'kickstart.plugins.lint',
- -- require 'kickstart.plugins.autopairs',
- -- require 'kickstart.plugins.neo-tree',
- -- require 'kickstart.plugins.gitsigns', -- adds gitsigns recommend keymaps
+ require 'kickstart.plugins.debug',
+ require 'kickstart.plugins.indent_line',
+ require 'kickstart.plugins.lint',
-- NOTE: The import below can automatically add your own plugins, configuration, etc from `lua/custom/plugins/*.lua`
-- This is the easiest way to modularize your config.
diff --git a/lazy-lock.json b/lazy-lock.json
new file mode 100644
index 00000000..898dc130
--- /dev/null
+++ b/lazy-lock.json
@@ -0,0 +1,41 @@
+{
+ "Comment.nvim": { "branch": "master", "commit": "0236521ea582747b58869cb72f70ccfa967d2e89" },
+ "LuaSnip": { "branch": "master", "commit": "a7a4b4682c4b3e2ba82b82a4e6e5f5a0e79dec32" },
+ "cmp-nvim-lsp": { "branch": "main", "commit": "5af77f54de1b16c34b23cba810150689a3a90312" },
+ "cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" },
+ "cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" },
+ "conform.nvim": { "branch": "master", "commit": "34b81e70da83e26c048290204de44268eb59814e" },
+ "copilot.lua": { "branch": "master", "commit": "03f825956ec49e550d07875d867ea6e7c4dc8c00" },
+ "fidget.nvim": { "branch": "main", "commit": "60404ba67044c6ab01894dd5bf77bd64ea5e09aa" },
+ "gitsigns.nvim": { "branch": "main", "commit": "2c2463dbd82eddd7dbab881c3a62cfbfbe3c67ae" },
+ "indent-blankline.nvim": { "branch": "master", "commit": "12e92044d313c54c438bd786d11684c88f6f78cd" },
+ "lazy.nvim": { "branch": "main", "commit": "aedcd79811d491b60d0a6577a9c1701063c2a609" },
+ "lualine.nvim": { "branch": "master", "commit": "7d131a8d3ba5016229e8a1d08bf8782acea98852" },
+ "markdown-preview.nvim": { "branch": "master", "commit": "a923f5fc5ba36a3b17e289dc35dc17f66d0548ee" },
+ "mason-lspconfig.nvim": { "branch": "main", "commit": "21d33d69a81f6351e5a5f49078b2e4f0075c8e73" },
+ "mason-nvim-dap.nvim": { "branch": "main", "commit": "67210c0e775adec55de9826b038e8b62de554afc" },
+ "mason-tool-installer.nvim": { "branch": "main", "commit": "1212fb6082b7177dde17ea65e429e027835aeb40" },
+ "mason.nvim": { "branch": "main", "commit": "3b5068f0fc565f337d67a2d315d935f574848ee7" },
+ "mini.nvim": { "branch": "main", "commit": "70d8a16399ca6df759d20bea302d6dfd710a1df8" },
+ "neo-tree.nvim": { "branch": "main", "commit": "e578fe7a5832421b0d2c5b3c0a7a1e40e0f6a47a" },
+ "neodev.nvim": { "branch": "main", "commit": "0ee95ecefc8ea45898a0383364f736e098c8703f" },
+ "nui.nvim": { "branch": "main", "commit": "35da9ca1de0fc4dda96c2e214d93d363c145f418" },
+ "nvim-cmp": { "branch": "main", "commit": "04e0ca376d6abdbfc8b52180f8ea236cbfddf782" },
+ "nvim-dap": { "branch": "master", "commit": "5a2f7121869394502521c52b2bc581ab22c69447" },
+ "nvim-dap-go": { "branch": "main", "commit": "5faf165f5062187320eaf9d177c3c1f647adc22e" },
+ "nvim-dap-ui": { "branch": "master", "commit": "5934302d63d1ede12c0b22b6f23518bb183fc972" },
+ "nvim-lint": { "branch": "master", "commit": "1f98d6c863f91706369d74aeb2eb3f02b2e96861" },
+ "nvim-lspconfig": { "branch": "master", "commit": "e5e600232188ed9fb960f5df6bb06084ae8bf3ec" },
+ "nvim-nio": { "branch": "master", "commit": "8765cbc4d0c629c8158a5341e1b4305fd93c3a90" },
+ "nvim-treesitter": { "branch": "master", "commit": "51d7c36e5f0d85429fe6eba6a59444f68cab7c6b" },
+ "onedark.nvim": { "branch": "master", "commit": "1230aaf2a427b2c5b73aba6e4a9a5881d3e69429" },
+ "plenary.nvim": { "branch": "master", "commit": "f7adfc4b3f4f91aab6caebf42b3682945fbc35be" },
+ "telescope-fzf-native.nvim": { "branch": "main", "commit": "9ef21b2e6bb6ebeaf349a0781745549bbb870d27" },
+ "telescope-ui-select.nvim": { "branch": "master", "commit": "6e51d7da30bd139a6950adf2a47fda6df9fa06d2" },
+ "telescope.nvim": { "branch": "0.1.x", "commit": "d90956833d7c27e73c621a61f20b29fdb7122709" },
+ "termicons.nvim": { "branch": "main", "commit": "ef5818d8380a19952576af159d433278a33d0119" },
+ "todo-comments.nvim": { "branch": "main", "commit": "833d8dd8b07eeda37a09e99460f72a02616935cb" },
+ "vim-be-good": { "branch": "master", "commit": "4fa57b7957715c91326fcead58c1fa898b9b3625" },
+ "vim-sleuth": { "branch": "master", "commit": "1cc4557420f215d02c4d2645a748a816c220e99b" },
+ "which-key.nvim": { "branch": "main", "commit": "4433e5ec9a507e5097571ed55c02ea9658fb268a" }
+}
\ No newline at end of file
diff --git a/lua/custom/plugins/copilot.lua b/lua/custom/plugins/copilot.lua
new file mode 100644
index 00000000..3f0e97e2
--- /dev/null
+++ b/lua/custom/plugins/copilot.lua
@@ -0,0 +1,50 @@
+return {
+ "zbirenbaum/copilot.lua",
+ cmd = "Copilot",
+ event = "InsertEnter",
+ config = function()
+ require('copilot').setup({
+ panel = {
+ enabled = true,
+ auto_refresh = false,
+ keymap = {
+ jump_prev = "[[",
+ jump_next = "]]",
+ accept = "",
+ refresh = "gr",
+ open = ""
+ },
+ layout = {
+ position = "bottom", -- | top | left | right
+ ratio = 0.4
+ },
+ },
+ suggestion = {
+ enabled = true,
+ auto_trigger = false,
+ debounce = 75,
+ keymap = {
+ accept = "",
+ accept_word = false,
+ accept_line = false,
+ next = "",
+ prev = "",
+ dismiss = "",
+ },
+ },
+ filetypes = {
+ yaml = false,
+ markdown = false,
+ help = false,
+ gitcommit = false,
+ gitrebase = false,
+ hgcommit = false,
+ svn = false,
+ cvs = false,
+ ["."] = false,
+ },
+ copilot_node_command = 'node', -- Node.js version must be > 18.x
+ server_opts_overrides = {},
+})
+ end
+}
diff --git a/lua/custom/plugins/filetree.lua b/lua/custom/plugins/filetree.lua
new file mode 100644
index 00000000..61bfebc0
--- /dev/null
+++ b/lua/custom/plugins/filetree.lua
@@ -0,0 +1,16 @@
+-- Unless you are still migrating, remove the deprecated commands from v1.x
+vim.cmd([[ let g:neo_tree_remove_legacy_commands = 1 ]])
+
+return {
+ "nvim-neo-tree/neo-tree.nvim",
+ version = "*",
+ dependencies = {
+ "nvim-lua/plenary.nvim",
+ "nvim-tree/nvim-web-devicons", -- not strictly required, but recommended
+ "MunifTanjim/nui.nvim",
+ "mskelton/termicons.nvim",
+ },
+ config = function ()
+ require('neo-tree').setup {}
+ end,
+}
diff --git a/lua/custom/plugins/init.lua b/lua/custom/plugins/init.lua
index be0eb9d8..4d488d2b 100644
--- a/lua/custom/plugins/init.lua
+++ b/lua/custom/plugins/init.lua
@@ -2,4 +2,6 @@
-- I promise not to create any merge conflicts in this directory :)
--
-- See the kickstart.nvim README for more information
+vim.wo.relativenumber = true
+vim.opt.guicursor = "n-v-i-c:block-Cursor"
return {}
diff --git a/lua/custom/plugins/markdown_preview.lua b/lua/custom/plugins/markdown_preview.lua
new file mode 100644
index 00000000..7d83606c
--- /dev/null
+++ b/lua/custom/plugins/markdown_preview.lua
@@ -0,0 +1,6 @@
+return {
+ "iamcco/markdown-preview.nvim",
+ cmd = { "MarkdownPreviewToggle", "MarkdownPreview", "MarkdownPreviewStop" },
+ ft = { "markdown" },
+ build = function() vim.fn["mkdp#util#install"]() end,
+}
diff --git a/lua/custom/plugins/vim_be_goog.lua b/lua/custom/plugins/vim_be_goog.lua
new file mode 100644
index 00000000..e340873b
--- /dev/null
+++ b/lua/custom/plugins/vim_be_goog.lua
@@ -0,0 +1,5 @@
+return {
+ {
+ 'ThePrimeagen/vim-be-good'
+ }
+}
diff --git a/lua/kickstart/plugins/debug.lua b/lua/kickstart/plugins/debug.lua
index 31dfecf5..7be4abdb 100644
--- a/lua/kickstart/plugins/debug.lua
+++ b/lua/kickstart/plugins/debug.lua
@@ -31,7 +31,7 @@ return {
require('mason-nvim-dap').setup {
-- Makes a best effort to setup the various debuggers with
-- reasonable debug configurations
- automatic_installation = true,
+ automatic_setup = true,
-- You can provide additional configuration to the handlers,
-- see mason-nvim-dap README for more information
@@ -85,12 +85,6 @@ return {
dap.listeners.before.event_exited['dapui_config'] = dapui.close
-- Install golang specific config
- require('dap-go').setup {
- delve = {
- -- On Windows delve must be run attached or it crashes.
- -- See https://github.com/leoluz/nvim-dap-go/blob/main/README.md#configuring
- detached = vim.fn.has 'win32' == 0,
- },
- }
+ require('dap-go').setup()
end,
}