1- vim .g .have_nerd_font = true
1+ -- Correct clipboard configuration (this was the main issue)
2+ vim .opt .clipboard :append ' unnamedplus' -- Use system clipboard for all operations
23
4+ -- Remove this line (it's not doing anything useful)
5+ -- vim.g.have_nerd_font = true -- This is a custom variable not used in your config
6+
7+ -- Rest of your configuration with some optimizations:
38vim .opt .number = true
49vim .opt .relativenumber = true
510vim .opt .mouse = ' a'
611vim .opt .showmode = false
712vim .opt .title = true
8- vim .opt .clipboard = ' unnamedplus'
913vim .opt .breakindent = true
1014vim .opt .undofile = true
1115vim .opt .ignorecase = true
@@ -30,26 +34,26 @@ vim.opt.path:append { '**' }
3034vim .opt .wildignore :append { ' */node_modules/*' }
3135vim .opt .formatoptions :append { ' r' }
3236
33- -- Enable folding in Neovim
37+ -- Improved folding configuration
3438vim .opt .foldmethod = ' expr'
3539vim .opt .foldexpr = ' nvim_treesitter#foldexpr()'
36- vim .opt .foldlevel = 99 -- Keep folds open by default
37- vim .opt .foldcolumn = ' 1' -- Show fold column left of line numbers
38-
39- vim .opt .foldtext = ' v:lua.custom_foldtext()' -- Custom fold text function
40+ vim .opt .foldlevel = 99
41+ vim .opt .foldcolumn = ' 1'
4042
41- -- Function to change fold symbols
43+ -- Custom fold text function (simplified)
4244function _G .custom_foldtext ()
43- local line = vim .fn .getline (vim .v .foldstart ) -- Get the first line of the fold
45+ local line = vim .trim ( vim . fn .getline (vim .v .foldstart ))
4446 local fold_size = vim .v .foldend - vim .v .foldstart + 1
45- return line .. ' ( ' .. fold_size .. ' lines) ' -- Display fold size
47+ return string.format ( ' ⏷ %s ⏤ %d lines ⏵ ' , line , fold_size )
4648end
4749
48- -- Customize fold markers in fold column
49- vim .opt .statuscolumn = ' %C' -- Customize fold column symbols
50+ vim .opt .foldtext = ' v:lua.custom_foldtext()'
51+
52+ -- Better fold characters configuration
5053vim .opt .fillchars :append {
51- foldopen = ' ▾' , -- Down arrow for open folds
52- foldclose = ' ▸' , -- Right arrow for closed folds
53- foldsep = ' ' , -- Space between folds
54- fold = ' ' , -- Empty space for better visuals
54+ foldopen = ' ' ,
55+ foldclose = ' ' ,
56+ fold = ' ' ,
57+ foldsep = ' ' ,
58+ diff = ' ╱' ,
5559}
0 commit comments