-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinit.lua
More file actions
54 lines (45 loc) · 1.19 KB
/
init.lua
File metadata and controls
54 lines (45 loc) · 1.19 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
print("hello nvim")
vim.cmd([[
set hidden
set vb t_vb=
set guioptions=
set fillchars=vert:\ ,fold:-
set list listchars=tab:\›\ ,trail:·,extends:>
set ts=2 sts=2 sw=2 expandtab
set incsearch
set smartcase
set ignorecase
set autoindent
set smartindent
set nomousehide
set nowrap
set novisualbell
set mouse=a
set wildignore+=*/.git/*,*/.hg/*,*/.svn/*,*.hi,*.o
set clipboard=unnamedplus
set lazyredraw
set autowrite
set notermguicolors
set t_Co=256
set signcolumn=yes
command! RemoveTrailingWhitespace :%s/\s\+$//
]])
require("config.lazy")
vim.keymap.set("n", "<space><space>x", "<cmd>source %<CR>")
vim.keymap.set("n", "<space>x", ".lua<CR>")
vim.keymap.set("v", "<space>x", ":lua<CR>")
vim.keymap.set("n", "<M-j>", "<cmd>cnext<CR>")
vim.keymap.set("n", "<M-k>", "<cmd>cprev<CR>")
vim.keymap.set("n", "-", "<cmd>Oil<CR>")
vim.keymap.set("n", "<space><tab>", ":b#<CR>")
vim.api.nvim_create_autocmd("TextYankPost", {
desc = 'Highlight when yanking text',
group = vim.api.nvim_create_augroup('kickstart-highlight-yank', { clear = true }),
callback = function()
vim.highlight.on_yank()
end,
})
vim.opt.inccommand = "nosplit"
vim.opt.encoding = "utf-8"
vim.g.mapleader = ","
vim.g.maplocalleader = "\\"