-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinit.lua
More file actions
36 lines (32 loc) · 890 Bytes
/
init.lua
File metadata and controls
36 lines (32 loc) · 890 Bytes
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
-- Make sure to setup `mapleader` and `maplocalleader` before
-- loading lazy.nvim so that mappings are correct.
-- This is also a good place to setup other settings (vim.opt)
require("config.keymaps")
require("config.options")
-- initialize lazy.nvim
require("config.lazy")
-- clipboard is in p (not "+ i.e +-registry)
vim.opt.clipboard = "unnamedplus"
-- initialize lsp
require("config.lsp")
-- nvim-treesitter
vim.api.nvim_create_autocmd('FileType', {
pattern = {
'python',
'javascript',
'jsx',
'typescript',
'tsx',
'lua',
'html',
'css',
'markdown'
},
callback = function()
vim.treesitter.start()
vim.wo[0][0].foldmethod = 'expr'
vim.wo[0][0].foldexpr = 'v:lua.vim.treesitter.foldexpr()'
vim.bo.indentexpr = "v:lua.require'nvim-treesitter'.indentexpr()"
vim.opt.foldenable = false -- disable folding on startup
end,
})