summary refs log tree commit diff
path: root/.config/nvim/lua/config/options.lua
blob: 073835f4a8f5debf13a28da770bce3ac6b1df5b1 (plain) (blame)
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
local opt = vim.opt

opt.number = true
opt.cursorline = true

-- connect system clipboard
opt.clipboard:prepend({ 'unnamedplus' })

-- preview supported ops in split buffer
opt.inccommand = 'split'

-- show whitespace indicators
opt.list = true
opt.listchars:append({
  trail = '¬',
  tab = '> ',
  -- space = '·',
  -- lead = '·',
})
opt.showbreak = '↪ '

-- show indicator and wrap text at 80 chars
opt.colorcolumn = '+1'
opt.textwidth = 80
opt.wrap = true

opt.conceallevel = 2
opt.concealcursor = nil

-- use treesitter to determine folds
opt.foldmethod = 'expr'
opt.foldexpr = 'v:lua.vim.treesitter.foldexpr()'
opt.foldlevel = 99

-- https://fosstodon.org/@rockorager/114183888444195197
opt.mousescroll = 'ver:1,hor:6'

-- load local vim config (will as to allow it)
opt.exrc = true