Skip to content

Commit 09a1c83

Browse files
.
1 parent 28121ba commit 09a1c83

File tree

1 file changed

+33
-106
lines changed

1 file changed

+33
-106
lines changed

init.lua

Lines changed: 33 additions & 106 deletions
Original file line numberDiff line numberDiff line change
@@ -1,101 +1,23 @@
11
--[[
2-
3-
=====================================================================
4-
==================== READ THIS BEFORE CONTINUING ====================
5-
=====================================================================
6-
======== .-----. ========
7-
======== .----------------------. | === | ========
8-
======== |.-""""""""""""""""""-.| |-----| ========
9-
======== || || | === | ========
10-
======== || KICKSTART.NVIM || |-----| ========
11-
======== || || | === | ========
12-
======== || || |-----| ========
13-
======== ||:Tutor || |:::::| ========
14-
======== |'-..................-'| |____o| ========
15-
======== `"")----------------(""` ___________ ========
16-
======== /::::::::::| |::::::::::\ \ no mouse \ ========
17-
======== /:::========| |==hjkl==:::\ \ required \ ========
18-
======== '""""""""""""' '""""""""""""' '""""""""""' ========
19-
======== ========
20-
=====================================================================
21-
=====================================================================
22-
23-
24-
25-
26-
27-
What is Kickstart?
28-
29-
Kickstart.nvim is *not* a distribution.
30-
31-
Kickstart.nvim is a starting point for your own configuration.
32-
The goal is that you can read every line of code, top-to-bottom, understand
33-
what your configuration is doing, and modify it to suit your needs.
34-
35-
Once you've done that, you can start exploring, configuring and tinkering to
36-
make Neovim your own! That might mean leaving Kickstart just the way it is for a while
37-
or immediately breaking it into modular pieces. It's up to you!
38-
39-
If you don't know anything about Lua, I recommend taking some time to read through
40-
a guide. One possible example which will only take 10-15 minutes:
41-
- https://learnxinyminutes.com/docs/lua/
42-
43-
After understanding a bit more about Lua, you can use `:help lua-guide` as a
44-
reference for how Neovim integrates Lua.
45-
- :help lua-guide
46-
- (or HTML version): https://neovim.io/doc/user/lua-guide.html
47-
48-
Kickstart Guide:
49-
50-
TODO: The very first thing you should do is to run the command `:Tutor` in Neovim.
51-
52-
If you don't know what this means, type the following:
53-
- <escape key>
54-
- :
55-
- Tutor
56-
- <enter key>
57-
58-
(If you already know the Neovim basics, you can skip this step.)
59-
60-
Once you've completed that, you can continue working through **AND READING** the rest
61-
of the kickstart init.lua.
62-
63-
Next, run AND READ `:help`.
64-
This will open up a help window with some basic information
65-
about reading, navigating and searching the builtin help documentation.
66-
67-
This should be the first place you go to look when you're stuck or confused
68-
with something. It's one of my favorite Neovim features.
69-
702
MOST IMPORTANTLY, we provide a keymap "<space>sh" to [s]earch the [h]elp documentation,
713
which is very useful when you're not exactly sure of what you're looking for.
72-
73-
I have left several `:help X` comments throughout the init.lua
74-
These are hints about where to find more information about the relevant settings,
75-
plugins or Neovim features used in Kickstart.
76-
77-
NOTE: Look for lines like this
78-
79-
Throughout the file. These are for you, the reader, to help you understand what is happening.
80-
Feel free to delete them once you know what you're doing, but they should serve as a guide
81-
for when you are first encountering a few different constructs in your Neovim config.
82-
83-
If you experience any errors while trying to install kickstart, run `:checkhealth` for more info.
84-
854
I hope you enjoy your Neovim journey,
865
- TJ
87-
88-
P.S. You can delete this when you're done too. It's your config now! :)
896
--]]
907

918
vim.api.nvim_set_keymap('n', 'Ø', ':E<CR>', { noremap = true, silent = true })
929
-- command line height standard 1
9310
vim.opt.cmdheight = 1
94-
11+
vim.api.nvim_set_keymap('n', 'ø', ':call feedkeys("\\r")<CR>', { noremap = true, silent = true })
12+
vim.api.nvim_set_keymap('v', 'ø', ':call feedkeys("\\r")<CR>', { noremap = true, silent = true })
13+
vim.api.nvim_set_keymap('o', 'ø', ':call feedkeys("\\r")<CR>', { noremap = true, silent = true })
14+
-- vim.api.nvim_set_keymap('n', 'ø', ":call feedkeys('\\<CR>')<CR>", { noremap = true, silent = true })
15+
-- vim.api.nvim_set_keymap('v', 'ø', ":call feedkeys('\\<CR>')<CR>", { noremap = true, silent = true })
16+
-- vim.api.nvim_set_keymap('o', 'ø', ":call feedkeys('\\<CR>')<CR>", { noremap = true, silent = true })
17+
-- vim.api.nvim_set_keymap('n', 'ø', ":call feedkeys('\\'..'<CR>'..')<CR>", { noremap = true, silent = true })
18+
-- vim.api.nvim_set_keymap('v', 'ø', ":call feedkeys('\\'..'<CR>'..')<CR>", { noremap = true, silent = true })
19+
-- vim.api.nvim_set_keymap('o', 'ø', ":call feedkeys('\\'..'<CR>'..')<CR>", { noremap = true, silent = true })
9520
-- Remap ø to <CR> in normal, visual, and operator-pending modes
96-
vim.api.nvim_set_keymap('n', 'ø', '<CR>', { noremap = true, silent = true })
97-
vim.api.nvim_set_keymap('v', 'ø', '<CR>', { noremap = true, silent = true })
98-
vim.api.nvim_set_keymap('o', 'ø', '<CR>', { noremap = true, silent = true })
9921

10022
-- Remap ø to <CR> in insert mode
10123
vim.api.nvim_set_keymap('i', 'ø', '<CR>', { noremap = true, silent = true })
@@ -353,7 +275,13 @@ require('lazy').setup({
353275
-- Optional dependencies
354276
dependencies = { { 'echasnovski/mini.icons', opts = {} } },
355277
config = function()
356-
require('oil').setup()
278+
require('oil').setup {
279+
delete_to_trash = true,
280+
view_options = {
281+
-- Show files and directories that start with "."
282+
show_hidden = true,
283+
},
284+
}
357285
vim.keymap.set('n', '-', '<CMD>Oil<CR>', { desc = 'Open parent directory' })
358286
end,
359287
-- dependencies = { "nvim-tree/nvim-web-devicons" }, -- use if prefer nvim-web-devicons
@@ -729,6 +657,17 @@ require('lazy').setup({
729657
'stevearc/conform.nvim',
730658
opts = {
731659
notify_on_error = false,
660+
keys = {
661+
{
662+
-- Customize or remove this keymap to your liking
663+
'<leader>f',
664+
function()
665+
require('conform').format { async = true }
666+
end,
667+
mode = '',
668+
desc = '[f]ormat buffer',
669+
},
670+
},
732671
format_on_save = function(bufnr)
733672
-- Disable "format_on_save lsp_fallback" for languages that don't
734673
-- have a well standardized coding style. You can add additional
@@ -742,6 +681,7 @@ require('lazy').setup({
742681
formatters_by_ft = {
743682
lua = { 'stylua' },
744683
ocaml = { 'ocamlformat', 'ocp-indent' },
684+
-- html = { { 'superhtml', 'djlint', 'htmlbeautifier' } },
745685
-- Conform can also run multiple formatters sequentially
746686
-- python = { "isort", "black" },
747687
--
@@ -860,37 +800,24 @@ require('lazy').setup({
860800
}
861801
end,
862802
},
863-
803+
{ 'miikanissi/modus-themes.nvim', priority = 1000 },
864804
{ -- You can easily change to a different colorscheme.
865805
-- This is where i config colorscheme / theme of nvim
866806
-- Change the name of the colorscheme plugin below, and then
867807
-- change the command in the config to whatever the name of that colorscheme is.
868808
--
869809
-- If you want to see what colorschemes are already installed, you can use `:Telescope colorscheme`.
870810

871-
'catppuccin/nvim',
811+
'rebelot/kanagawa.nvim',
812+
-- 'catppuccin/nvim',
872813
priority = 1000, -- Make sure to load this before all the other start plugins.
873814
init = function()
874-
require('catppuccin').setup {
875-
-- color_overrides = {
876-
-- all = {},
877-
-- latte = {
878-
-- base = '#ffffff',
879-
-- mantle = '#000000',
880-
-- crust = '#474747',
881-
-- },
882-
-- },
883-
custom_highlights = function(colors)
884-
return {
885-
Comment = { fg = colors.pink },
886-
}
887-
end,
888-
}
889815
-- Load the colorscheme here.
890816
-- Like many other themes, this one has different styles, and you could load
891817
-- any other, such as 'tokyonight-storm', 'tokyonight-moon', or 'tokyonight-day'.
892818

893-
vim.cmd.colorscheme 'catppuccin-latte'
819+
-- vim.cmd.colorscheme 'kanagawa-dragon'
820+
vim.cmd.colorscheme 'modus_vivendi'
894821
-- vim.cmd.colorscheme 'rose-pine-dawn'
895822
-- You can configure highlights by doing something like:
896823
vim.cmd.hi 'Comment gui=none'

0 commit comments

Comments
 (0)