File tree Expand file tree Collapse file tree 2 files changed +16
-5
lines changed
tests/test-sources/plugins/bufferlines Expand file tree Collapse file tree 2 files changed +16
-5
lines changed Original file line number Diff line number Diff line change 55 ...
66} :
77let
8- inherit ( lib ) mkEnableOption genAttrs ;
98 inherit ( lib . nixvim ) defaultNullOpts nixvimTypes ;
109 types = nixvimTypes ;
1110
@@ -112,7 +111,6 @@ lib.nixvim.neovim-plugin.mkNeovimPlugin config {
112111 "sortBy"
113112 "diagnostics"
114113 "diagnosticsIndicator"
115- "diagnosticsUpdateInInsert"
116114 "offsets"
117115 [
118116 "groups"
@@ -391,7 +389,7 @@ lib.nixvim.neovim-plugin.mkNeovimPlugin config {
391389 } ;
392390
393391 hover = {
394- enabled = mkEnableOption "hover" ;
392+ enabled = lib . mkEnableOption "hover" ;
395393
396394 reveal = defaultNullOpts . mkListOf types . str [ ] "reveal" ;
397395
@@ -413,14 +411,20 @@ lib.nixvim.neovim-plugin.mkNeovimPlugin config {
413411 optionSnakeCase
414412 ) ( oldHighlightOptions ++ [ "truncMarker" ] ) ;
415413 in
416- genAttrs newHighlightsOptions (
414+ lib . genAttrs newHighlightsOptions (
417415 name :
418416 defaultNullOpts . mkHighlight { } null ''
419417 Highlight group definition for ${ name } .
420418 ''
421419 ) ;
422420 } ;
423421
422+ extraOptions = {
423+ diagnosticsUpdateInInsert = defaultNullOpts . mkBool true ''
424+ Whether diagnostics should update in insert mode.
425+ '' ;
426+ } ;
427+
424428 settingsExample = {
425429 options = {
426430 mode = "buffers" ;
@@ -563,6 +567,12 @@ lib.nixvim.neovim-plugin.mkNeovimPlugin config {
563567 } ;
564568
565569 extraConfig = cfg : {
570+ extraConfigLua =
571+ lib . optionalString ( cfg . diagnosticsUpdateInInsert != null ) # Lua
572+ ''
573+ vim.diagnostic.config { update_in_insert = ${ toString cfg . diagnosticsUpdateInInsert } }
574+ '' ;
575+
566576 extraPlugins = with pkgs . vimPlugins ; [
567577 cfg . package
568578 nvim-web-devicons
Original file line number Diff line number Diff line change 4747 defaults = {
4848 plugins . bufferline = {
4949 enable = true ;
50+ diagnosticsUpdateInInsert = true ;
51+
5052 settings = {
5153 options = {
5254 mode = "buffers" ;
8486 sort_by = "id" ;
8587 diagnostics = false ;
8688 diagnostics_indicator = null ;
87- diagnostics_update_in_insert = true ;
8889 offsets = null ;
8990 groups = {
9091 items = [ ] ;
You can’t perform that action at this time.
0 commit comments