@@ -29,7 +29,7 @@ What is Kickstart?
29
29
what your configuration is doing, and modify it to suit your needs.
30
30
31
31
Once you've done that, you can start exploring, configuring and tinkering to
32
- make Neovim your own! That might mean leaving kickstart just the way it is for a while
32
+ make Neovim your own! That might mean leaving Kickstart just the way it is for a while
33
33
or immediately breaking it into modular pieces. It's up to you!
34
34
35
35
If you don't know anything about Lua, I recommend taking some time to read through
@@ -51,32 +51,32 @@ Kickstart Guide:
51
51
- Tutor
52
52
- <enter key>
53
53
54
- (If you already know how the Neovim basics, you can skip this step)
54
+ (If you already know the Neovim basics, you can skip this step. )
55
55
56
56
Once you've completed that, you can continue working through **AND READING** the rest
57
- of the kickstart init.lua
57
+ of the kickstart init.lua.
58
58
59
59
Next, run AND READ `:help`.
60
60
This will open up a help window with some basic information
61
61
about reading, navigating and searching the builtin help documentation.
62
62
63
63
This should be the first place you go to look when you're stuck or confused
64
- with something. It's one of my favorite neovim features.
64
+ with something. It's one of my favorite Neovim features.
65
65
66
66
MOST IMPORTANTLY, we provide a keymap "<space>sh" to [s]earch the [h]elp documentation,
67
- which is very useful when you're not sure exactly what you're looking for.
67
+ which is very useful when you're not exactly sure of what you're looking for.
68
68
69
69
I have left several `:help X` comments throughout the init.lua
70
70
These are hints about where to find more information about the relevant settings,
71
- plugins or neovim features used in kickstart .
71
+ plugins or Neovim features used in Kickstart .
72
72
73
73
NOTE: Look for lines like this
74
74
75
- Throughout the file. These are for you, the reader, to help understand what is happening.
75
+ Throughout the file. These are for you, the reader, to help you understand what is happening.
76
76
Feel free to delete them once you know what you're doing, but they should serve as a guide
77
- for when you are first encountering a few different constructs in your nvim config.
77
+ for when you are first encountering a few different constructs in your Neovim config.
78
78
79
- If you experience any errors while trying to install kickstart, run `:checkhealth` for more info
79
+ If you experience any errors while trying to install kickstart, run `:checkhealth` for more info.
80
80
81
81
I hope you enjoy your Neovim journey,
82
82
- TJ
@@ -100,14 +100,14 @@ vim.g.have_nerd_font = false
100
100
101
101
-- Make line numbers default
102
102
vim .opt .number = true
103
- -- You can also add relative line numbers, for help with jumping.
103
+ -- You can also add relative line numbers, to help with jumping.
104
104
-- Experiment for yourself to see if you like it!
105
105
-- vim.opt.relativenumber = true
106
106
107
107
-- Enable mouse mode, can be useful for resizing splits for example!
108
108
vim .opt .mouse = ' a'
109
109
110
- -- Don't show the mode, since it's already in status line
110
+ -- Don't show the mode, since it's already in the status line
111
111
vim .opt .showmode = false
112
112
113
113
-- Sync clipboard between OS and Neovim.
@@ -121,7 +121,7 @@ vim.opt.breakindent = true
121
121
-- Save undo history
122
122
vim .opt .undofile = true
123
123
124
- -- Case-insensitive searching UNLESS \C or capital in search
124
+ -- Case-insensitive searching UNLESS \C or one or more capital letters in the search term
125
125
vim .opt .ignorecase = true
126
126
vim .opt .smartcase = true
127
127
@@ -139,7 +139,7 @@ vim.opt.timeoutlen = 300
139
139
vim .opt .splitright = true
140
140
vim .opt .splitbelow = true
141
141
142
- -- Sets how neovim will display certain whitespace in the editor.
142
+ -- Sets how neovim will display certain whitespace characters in the editor.
143
143
-- See `:help 'list'`
144
144
-- and `:help 'listchars'`
145
145
vim .opt .list = true
@@ -220,7 +220,7 @@ vim.opt.rtp:prepend(lazypath)
220
220
--
221
221
-- You can press `?` in this menu for help. Use `:q` to close the window
222
222
--
223
- -- To update plugins, you can run
223
+ -- To update plugins you can run
224
224
-- :Lazy update
225
225
--
226
226
-- NOTE: Here is where you install your plugins.
@@ -241,7 +241,7 @@ require('lazy').setup({
241
241
{ ' numToStr/Comment.nvim' , opts = {} },
242
242
243
243
-- Here is a more advanced example where we pass configuration
244
- -- options to `gitsigns.nvim`. This is equivalent to the following lua :
244
+ -- options to `gitsigns.nvim`. This is equivalent to the following Lua :
245
245
-- require('gitsigns').setup({ ... })
246
246
--
247
247
-- See `:help gitsigns` to understand what the configuration keys do
@@ -258,7 +258,7 @@ require('lazy').setup({
258
258
},
259
259
},
260
260
261
- -- NOTE: Plugins can also be configured to run lua code when they are loaded.
261
+ -- NOTE: Plugins can also be configured to run Lua code when they are loaded.
262
262
--
263
263
-- This is often very useful to both group configuration, as well as handle
264
264
-- lazy loading plugins that don't need to be loaded immediately at startup.
@@ -303,7 +303,7 @@ require('lazy').setup({
303
303
branch = ' 0.1.x' ,
304
304
dependencies = {
305
305
' nvim-lua/plenary.nvim' ,
306
- { -- If encountering errors, see telescope-fzf-native README for install instructions
306
+ { -- If encountering errors, see telescope-fzf-native README for installation instructions
307
307
' nvim-telescope/telescope-fzf-native.nvim' ,
308
308
309
309
-- `build` is used to run some command when the plugin is installed/updated.
@@ -326,19 +326,19 @@ require('lazy').setup({
326
326
-- it can fuzzy find! It's more than just a "file finder", it can search
327
327
-- many different aspects of Neovim, your workspace, LSP, and more!
328
328
--
329
- -- The easiest way to use telescope , is to start by doing something like:
329
+ -- The easiest way to use Telescope , is to start by doing something like:
330
330
-- :Telescope help_tags
331
331
--
332
332
-- After running this command, a window will open up and you're able to
333
- -- type in the prompt window. You'll see a list of help_tags options and
333
+ -- type in the prompt window. You'll see a list of ` help_tags` options and
334
334
-- a corresponding preview of the help.
335
335
--
336
- -- Two important keymaps to use while in telescope are:
336
+ -- Two important keymaps to use while in Telescope are:
337
337
-- - Insert mode: <c-/>
338
338
-- - Normal mode: ?
339
339
--
340
340
-- This opens a window that shows you all of the keymaps for the current
341
- -- telescope picker. This is really useful to discover what Telescope can
341
+ -- Telescope picker. This is really useful to discover what Telescope can
342
342
-- do as well as how to actually do it!
343
343
344
344
-- [[ Configure Telescope ]]
@@ -360,7 +360,7 @@ require('lazy').setup({
360
360
},
361
361
}
362
362
363
- -- Enable telescope extensions, if they are installed
363
+ -- Enable Telescope extensions if they are installed
364
364
pcall (require (' telescope' ).load_extension , ' fzf' )
365
365
pcall (require (' telescope' ).load_extension , ' ui-select' )
366
366
@@ -379,14 +379,14 @@ require('lazy').setup({
379
379
380
380
-- Slightly advanced example of overriding default behavior and theme
381
381
vim .keymap .set (' n' , ' <leader>/' , function ()
382
- -- You can pass additional configuration to telescope to change theme, layout, etc.
382
+ -- You can pass additional configuration to Telescope to change the theme, layout, etc.
383
383
builtin .current_buffer_fuzzy_find (require (' telescope.themes' ).get_dropdown {
384
384
winblend = 10 ,
385
385
previewer = false ,
386
386
})
387
387
end , { desc = ' [/] Fuzzily search in current buffer' })
388
388
389
- -- Also possible to pass additional configuration options.
389
+ -- It's also possible to pass additional configuration options.
390
390
-- See `:help telescope.builtin.live_grep()` for information about particular keys
391
391
vim .keymap .set (' n' , ' <leader>s/' , function ()
392
392
builtin .live_grep {
@@ -395,7 +395,7 @@ require('lazy').setup({
395
395
}
396
396
end , { desc = ' [S]earch [/] in Open Files' })
397
397
398
- -- Shortcut for searching your neovim configuration files
398
+ -- Shortcut for searching your Neovim configuration files
399
399
vim .keymap .set (' n' , ' <leader>sn' , function ()
400
400
builtin .find_files { cwd = vim .fn .stdpath ' config' }
401
401
end , { desc = ' [S]earch [N]eovim files' })
@@ -405,7 +405,7 @@ require('lazy').setup({
405
405
{ -- LSP Configuration & Plugins
406
406
' neovim/nvim-lspconfig' ,
407
407
dependencies = {
408
- -- Automatically install LSPs and related tools to stdpath for neovim
408
+ -- Automatically install LSPs and related tools to stdpath for Neovim
409
409
' williamboman/mason.nvim' ,
410
410
' williamboman/mason-lspconfig.nvim' ,
411
411
' WhoIsSethDaniel/mason-tool-installer.nvim' ,
@@ -419,15 +419,15 @@ require('lazy').setup({
419
419
{ ' folke/neodev.nvim' , opts = {} },
420
420
},
421
421
config = function ()
422
- -- Brief Aside : **What is LSP?**
422
+ -- Brief aside : **What is LSP?**
423
423
--
424
- -- LSP is an acronym you've probably heard, but might not understand what it is.
424
+ -- LSP is an initialism you've probably heard, but might not understand what it is.
425
425
--
426
426
-- LSP stands for Language Server Protocol. It's a protocol that helps editors
427
427
-- and language tooling communicate in a standardized fashion.
428
428
--
429
429
-- In general, you have a "server" which is some tool built to understand a particular
430
- -- language (such as `gopls`, `lua_ls`, `rust_analyzer`, etc). These Language Servers
430
+ -- language (such as `gopls`, `lua_ls`, `rust_analyzer`, etc. ). These Language Servers
431
431
-- (sometimes called LSP servers, but that's kind of like ATM Machine) are standalone
432
432
-- processes that communicate with some "client" - in this case, Neovim!
433
433
--
@@ -451,9 +451,8 @@ require('lazy').setup({
451
451
vim .api .nvim_create_autocmd (' LspAttach' , {
452
452
group = vim .api .nvim_create_augroup (' kickstart-lsp-attach' , { clear = true }),
453
453
callback = function (event )
454
- -- NOTE: Remember that lua is a real programming language, and as such it is possible
455
- -- to define small helper and utility functions so you don't have to repeat yourself
456
- -- many times.
454
+ -- NOTE: Remember that Lua is a real programming language, and as such it is possible
455
+ -- to define small helper and utility functions so you don't have to repeat yourself.
457
456
--
458
457
-- In this case, we create a function that lets us more easily define mappings specific
459
458
-- for LSP related items. It sets the mode, buffer and description for us each time.
@@ -482,11 +481,11 @@ require('lazy').setup({
482
481
-- Symbols are things like variables, functions, types, etc.
483
482
map (' <leader>ds' , require (' telescope.builtin' ).lsp_document_symbols , ' [D]ocument [S]ymbols' )
484
483
485
- -- Fuzzy find all the symbols in your current workspace
486
- -- Similar to document symbols, except searches over your whole project.
484
+ -- Fuzzy find all the symbols in your current workspace.
485
+ -- Similar to document symbols, except searches over your entire project.
487
486
map (' <leader>ws' , require (' telescope.builtin' ).lsp_dynamic_workspace_symbols , ' [W]orkspace [S]ymbols' )
488
487
489
- -- Rename the variable under your cursor
488
+ -- Rename the variable under your cursor.
490
489
-- Most Language Servers support renaming across files, etc.
491
490
map (' <leader>rn' , vim .lsp .buf .rename , ' [R]e[n]ame' )
492
491
@@ -495,11 +494,11 @@ require('lazy').setup({
495
494
map (' <leader>ca' , vim .lsp .buf .code_action , ' [C]ode [A]ction' )
496
495
497
496
-- Opens a popup that displays documentation about the word under your cursor
498
- -- See `:help K` for why this keymap
497
+ -- See `:help K` for why this keymap.
499
498
map (' K' , vim .lsp .buf .hover , ' Hover Documentation' )
500
499
501
500
-- WARN: This is not Goto Definition, this is Goto Declaration.
502
- -- For example, in C this would take you to the header
501
+ -- For example, in C this would take you to the header.
503
502
map (' gD' , vim .lsp .buf .declaration , ' [G]oto [D]eclaration' )
504
503
505
504
-- The following two autocommands are used to highlight references of the
@@ -523,7 +522,7 @@ require('lazy').setup({
523
522
})
524
523
525
524
-- LSP servers and clients are able to communicate to each other what features they support.
526
- -- By default, Neovim doesn't support everything that is in the LSP Specification .
525
+ -- By default, Neovim doesn't support everything that is in the LSP specification .
527
526
-- When you add nvim-cmp, luasnip, etc. Neovim now has *more* capabilities.
528
527
-- So, we create new capabilities with nvim cmp, and then broadcast that to the servers.
529
528
local capabilities = vim .lsp .protocol .make_client_capabilities ()
@@ -573,14 +572,14 @@ require('lazy').setup({
573
572
-- other tools, you can run
574
573
-- :Mason
575
574
--
576
- -- You can press `g?` for help in this menu
575
+ -- You can press `g?` for help in this menu.
577
576
require (' mason' ).setup ()
578
577
579
578
-- You can add other tools here that you want Mason to install
580
579
-- for you, so that they are available from within Neovim.
581
580
local ensure_installed = vim .tbl_keys (servers or {})
582
581
vim .list_extend (ensure_installed , {
583
- ' stylua' , -- Used to format lua code
582
+ ' stylua' , -- Used to format Lua code
584
583
})
585
584
require (' mason-tool-installer' ).setup { ensure_installed = ensure_installed }
586
585
@@ -633,9 +632,9 @@ require('lazy').setup({
633
632
{
634
633
' L3MON4D3/LuaSnip' ,
635
634
build = (function ()
636
- -- Build Step is needed for regex support in snippets
637
- -- This step is not supported in many windows environments
638
- -- Remove the below condition to re-enable on windows
635
+ -- Build Step is needed for regex support in snippets.
636
+ -- This step is not supported in many windows environments.
637
+ -- Remove the below condition to re-enable on windows.
639
638
if vim .fn .has ' win32' == 1 or vim .fn .executable ' make' == 0 then
640
639
return
641
640
end
@@ -685,7 +684,7 @@ require('lazy').setup({
685
684
-- Select the [p]revious item
686
685
[' <C-p>' ] = cmp .mapping .select_prev_item (),
687
686
688
- -- scroll the documentation window [b]ack / [f]orward
687
+ -- Scroll the documentation window [b]ack / [f]orward
689
688
[' <C-b>' ] = cmp .mapping .scroll_docs (- 4 ),
690
689
[' <C-f>' ] = cmp .mapping .scroll_docs (4 ),
691
690
@@ -718,7 +717,7 @@ require('lazy').setup({
718
717
end
719
718
end , { ' i' , ' s' }),
720
719
721
- -- For more advanced luasnip keymaps (e.g. selecting choice nodes, expansion) see:
720
+ -- For more advanced Luasnip keymaps (e.g. selecting choice nodes, expansion) see:
722
721
-- https://github.com/L3MON4D3/LuaSnip?tab=readme-ov-file#keymaps
723
722
},
724
723
sources = {
@@ -732,18 +731,18 @@ require('lazy').setup({
732
731
733
732
{ -- You can easily change to a different colorscheme.
734
733
-- Change the name of the colorscheme plugin below, and then
735
- -- change the command in the config to whatever the name of that colorscheme is
734
+ -- change the command in the config to whatever the name of that colorscheme is.
736
735
--
737
- -- If you want to see what colorschemes are already installed, you can use `:Telescope colorscheme`
736
+ -- If you want to see what colorschemes are already installed, you can use `:Telescope colorscheme`.
738
737
' folke/tokyonight.nvim' ,
739
- priority = 1000 , -- make sure to load this before all the other start plugins
738
+ priority = 1000 , -- Make sure to load this before all the other start plugins.
740
739
init = function ()
741
740
-- Load the colorscheme here.
742
741
-- Like many other themes, this one has different styles, and you could load
743
742
-- any other, such as 'tokyonight-storm', 'tokyonight-moon', or 'tokyonight-day'.
744
743
vim .cmd .colorscheme ' tokyonight-night'
745
744
746
- -- You can configure highlights by doing something like
745
+ -- You can configure highlights by doing something like:
747
746
vim .cmd .hi ' Comment gui=none'
748
747
end ,
749
748
},
@@ -788,7 +787,6 @@ require('lazy').setup({
788
787
-- Check out: https://github.com/echasnovski/mini.nvim
789
788
end ,
790
789
},
791
-
792
790
{ -- Highlight, edit, and navigate code
793
791
' nvim-treesitter/nvim-treesitter' ,
794
792
build = ' :TSUpdate' ,
@@ -822,11 +820,11 @@ require('lazy').setup({
822
820
823
821
-- The following two comments only work if you have downloaded the kickstart repo, not just copy pasted the
824
822
-- init.lua. If you want these files, they are in the repository, so you can just download them and
825
- -- put them in the right spots if you want .
823
+ -- place them in the correct locations .
826
824
827
- -- NOTE: Next step on your Neovim journey: Add/Configure additional plugins for kickstart
825
+ -- NOTE: Next step on your Neovim journey: Add/Configure additional plugins for Kickstart
828
826
--
829
- -- Here are some example plugins that I've included in the kickstart repository.
827
+ -- Here are some example plugins that I've included in the Kickstart repository.
830
828
-- Uncomment any of the lines below to enable them (you will need to restart nvim).
831
829
--
832
830
-- require 'kickstart.plugins.debug',
@@ -841,8 +839,8 @@ require('lazy').setup({
841
839
-- { import = 'custom.plugins' },
842
840
}, {
843
841
ui = {
844
- -- If you have a Nerd Font, set icons to an empty table which will use the
845
- -- default lazy.nvim defined Nerd Font icons otherwise define a unicode icons table
842
+ -- If you are using a Nerd Font: set icons to an empty table which will use the
843
+ -- default lazy.nvim defined Nerd Font icons, otherwise define a unicode icons table
846
844
icons = vim .g .have_nerd_font and {} or {
847
845
cmd = ' ⌘' ,
848
846
config = ' 🛠' ,
0 commit comments