From 7190ee4b87b854480512f8180bea6f9d98b5ed45 Mon Sep 17 00:00:00 2001 From: NotAShelf Date: Sat, 5 Aug 2023 21:33:31 +0300 Subject: [PATCH 1/8] fix: lua syntax mismatch for global formatting and nix language the nix expression for formatter configuration were missing two curly closing brackets --- modules/languages/nix.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/languages/nix.nix b/modules/languages/nix.nix index 26f9285..5ee616c 100644 --- a/modules/languages/nix.nix +++ b/modules/languages/nix.nix @@ -56,9 +56,9 @@ with builtins; let command = {"${cfg.format.package}/bin/nixpkgs-fmt"}, }, ''} - ''} }, - }; + }, + ''} } ''; }; From 6ab7d7667d0f7c43194c20b20c90b33e72ef95ff Mon Sep 17 00:00:00 2001 From: NotAShelf Date: Mon, 7 Aug 2023 14:56:29 +0300 Subject: [PATCH 2/8] feat: build orgmode grammar manually --- modules/notes/orgmode/config.nix | 57 +++++++++++++++++-------------- modules/notes/orgmode/orgmode.nix | 9 +++++ 2 files changed, 41 insertions(+), 25 deletions(-) diff --git a/modules/notes/orgmode/config.nix b/modules/notes/orgmode/config.nix index 355610d..1dadb50 100644 --- a/modules/notes/orgmode/config.nix +++ b/modules/notes/orgmode/config.nix @@ -7,33 +7,40 @@ with lib; with builtins; let cfg = config.vim.notes.orgmode; in { - config = mkIf (cfg.enable) { - vim.startPlugins = [ - "orgmode-nvim" - ]; + config = mkIf cfg.enable (mkMerge [ + { + vim.startPlugins = [ + "orgmode-nvim" + ]; - vim.luaConfigRC.orgmode = nvim.dag.entryAnywhere '' - -- Load custom treesitter grammar for org filetype - require('orgmode').setup_ts_grammar() + vim.luaConfigRC.orgmode = nvim.dag.entryAnywhere '' + -- Load custom treesitter grammar for org filetype + require('orgmode').setup_ts_grammar() - -- Treesitter configuration - require('nvim-treesitter.configs').setup { + -- Treesitter configuration + require('nvim-treesitter.configs').setup { - -- If TS highlights are not enabled at all, or disabled via `disable` prop, - -- highlighting will fallback to default Vim syntax highlighting - highlight = { - enable = true, - -- Required for spellcheck, some LaTex highlights and - -- code block highlights that do not have ts grammar - additional_vim_regex_highlighting = {'org'}, - }, - ensure_installed = {'org'}, -- Or run :TSUpdate org - } + -- If TS highlights are not enabled at all, or disabled via `disable` prop, + -- highlighting will fallback to default Vim syntax highlighting + highlight = { + enable = true, + -- Required for spellcheck, some LaTex highlights and + -- code block highlights that do not have ts grammar + additional_vim_regex_highlighting = {'org'}, + }, + } - require('orgmode').setup({ - org_agenda_files = ${cfg.orgAgendaFiles}, - org_default_notes_file = '${cfg.orgDefaultNotesFile}', - }) - ''; - }; + require('orgmode').setup({ + org_agenda_files = ${cfg.orgAgendaFiles}, + org_default_notes_file = '${cfg.orgDefaultNotesFile}', + }) + ''; + } + + (mkIf cfg.treesitter.enable { + vim.treesitter.enable = true; + + vim.treesitter.grammars = [cfg.treesitter.orgPackage]; + }) + ]); } diff --git a/modules/notes/orgmode/orgmode.nix b/modules/notes/orgmode/orgmode.nix index 3ba9e30..fee0c4b 100644 --- a/modules/notes/orgmode/orgmode.nix +++ b/modules/notes/orgmode/orgmode.nix @@ -1,21 +1,30 @@ { config, lib, + pkgs, ... }: with lib; with builtins; { options.vim.notes.orgmode = { enable = mkEnableOption "nvim-orgmode: Neovim plugin for Emac Orgmode. Get the best of both worlds"; + orgAgendaFiles = mkOption { type = types.str; default = "{'~/Documents/org/*', '~/my-orgs/**/*'}"; description = "List of org files to be used as agenda files."; }; + orgDefaultNotesFile = mkOption { type = types.str; default = "~/Documents/org/refile.org"; description = "Default org file to be used for notes."; }; + + treesitter = { + enable = mkEnableOption "Enable Orgmode treesitter" // {default = config.vim.languages.enableTreesitter;}; + + orgPackage = nvim.types.mkGrammarOption pkgs "org"; + }; }; } From 13878ce081f8c5182d27caefad3bfa0c04d4db7a Mon Sep 17 00:00:00 2001 From: AmanSe Date: Wed, 9 Aug 2023 10:11:48 +0530 Subject: [PATCH 3/8] feat: Initial jdtls support --- configuration.nix | 1 + modules/languages/default.nix | 1 + modules/languages/java.nix | 45 +++++++++++++++++++++++++++++++++++ 3 files changed, 47 insertions(+) create mode 100644 modules/languages/java.nix diff --git a/configuration.nix b/configuration.nix index 718b4d2..9718a4b 100644 --- a/configuration.nix +++ b/configuration.nix @@ -64,6 +64,7 @@ inputs: let enable = isMaximal; crates.enable = true; }; + java.enable = isMaximal; ts.enable = isMaximal; svelte.enable = isMaximal; go.enable = isMaximal; diff --git a/modules/languages/default.nix b/modules/languages/default.nix index 9a5135e..2011971 100644 --- a/modules/languages/default.nix +++ b/modules/languages/default.nix @@ -23,6 +23,7 @@ in { ./zig.nix ./html.nix ./svelte.nix + ./java.nix ]; options.vim.languages = { diff --git a/modules/languages/java.nix b/modules/languages/java.nix new file mode 100644 index 0000000..1792824 --- /dev/null +++ b/modules/languages/java.nix @@ -0,0 +1,45 @@ +{ + pkgs, + config, + lib, + ... +}: +with lib; +with builtins; let + cfg = config.vim.languages.java; +in { + options.vim.languages.java = { + enable = mkEnableOption "Java language support"; + + treesitter = { + enable = mkEnableOption "Enable Java treesitter" // {default = config.vim.languages.enableTreesitter;}; + package = nvim.types.mkGrammarOption pkgs "java"; + }; + + lsp = { + enable = mkEnableOption "Java LSP support (java-language-server)" // {default = config.vim.languages.enableLSP;}; + + package = mkOption { + description = "java language server"; + type = types.package; + default = pkgs.jdt-language-server; + }; + }; + }; + + config = mkIf cfg.enable (mkMerge [ + (mkIf cfg.lsp.enable { + vim.lsp.lspconfig.enable = true; + vim.lsp.lspconfig.sources.jdtls = '' + lspconfig.jdtls.setup { + cmd = {"${cfg.lsp.package}/bin/jdt-language-server", "-data", vim.fn.stdpath("cache").."/jdtls/workspace"}, + } + ''; + }) + + (mkIf cfg.treesitter.enable { + vim.treesitter.enable = true; + vim.treesitter.grammars = [cfg.treesitter.package]; + }) + ]); +} From 1a9679375037faf83ad7dea168b8dfa8991ae1d4 Mon Sep 17 00:00:00 2001 From: AmanSe Date: Wed, 9 Aug 2023 17:07:43 +0530 Subject: [PATCH 4/8] docs: add release note entry --- docs/release-notes/rl-0.5.adoc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docs/release-notes/rl-0.5.adoc b/docs/release-notes/rl-0.5.adoc index 5b45d11..78c18f5 100644 --- a/docs/release-notes/rl-0.5.adoc +++ b/docs/release-notes/rl-0.5.adoc @@ -16,7 +16,9 @@ https://github.com/horriblename[horriblename]: https://github.com/amanse[amanse]: -* Added daily notes options for obsidian plugin.a +* Added daily notes options for obsidian plugin. + +* Added jdt-language-server for Java. https://github.com/yavko[yavko]: From 35ea9e5da3601745d649c291b1592f2586ce5596 Mon Sep 17 00:00:00 2001 From: NotAShelf Date: Thu, 10 Aug 2023 17:42:54 +0300 Subject: [PATCH 5/8] fix: add missing args to the dracula setup --- modules/theme/supported_themes.nix | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/modules/theme/supported_themes.nix b/modules/theme/supported_themes.nix index 1d36628..d9459f1 100644 --- a/modules/theme/supported_themes.nix +++ b/modules/theme/supported_themes.nix @@ -27,8 +27,13 @@ }; dracula = { - setup = '' - require('dracula').setup({}); + setup = { + style ? null, + transparent, + }: '' + require('dracula').setup({ + transparent_bg = ${lib.boolToString transparent}, + }); require('dracula').load(); ''; }; From a9430961e8417cb31b19b2f03a0f5a54855109db Mon Sep 17 00:00:00 2001 From: NotAShelf Date: Thu, 10 Aug 2023 19:35:45 +0300 Subject: [PATCH 6/8] dev: clean up breadcrumbs module potentially avoid unwanted plugin loads --- modules/ui/breadcrumbs/config.nix | 268 +++++++++++++++--------------- 1 file changed, 137 insertions(+), 131 deletions(-) diff --git a/modules/ui/breadcrumbs/config.nix b/modules/ui/breadcrumbs/config.nix index 18e84f0..730f493 100644 --- a/modules/ui/breadcrumbs/config.nix +++ b/modules/ui/breadcrumbs/config.nix @@ -18,146 +18,152 @@ in { [ "nvim-lspconfig" ] + ++ lib.optionals (cfg.source == "nvim-navic") [ + "nvim-navic" + ] ++ lib.optionals (config.vim.lsp.lspsaga.enable && cfg.source == "lspsaga") [ "lspsaga" ] - ++ lib.optionals (cfg.navbuddy.enable || cfg.source == "nvim-navic") [ + ++ lib.optionals cfg.navbuddy.enable [ "nvim-navbuddy" - "nvim-navic" + "nui-nvim" ]; vim.luaConfigRC.breadcrumbs = nvim.dag.entryAfter ["lspconfig"] '' - local navbuddy = require("nvim-navbuddy") - local navic = require("nvim-navic") - local actions = require("nvim-navbuddy.actions") - require("nvim-navic").setup { - highlight = true - } - - -- TODO: wrap this in an optional string with navbuddy as the enable condition - navbuddy.setup { - window = { - border = "${nb.window.border}", -- "rounded", "double", "solid", "none" - size = "60%", - position = "50%", - scrolloff = ${(nilOrStr nb.window.scrolloff)}, - sections = { - left = { - size = "20%", - border = ${(nilOrStr nb.window.sections.left.border)}, - }, - - mid = { - size = "40%", - border = ${(nilOrStr nb.window.sections.mid.border)}, - }, - - right = { - border = ${(nilOrStr nb.window.sections.right.border)}, - preview = "leaf", - } - }, - }, - node_markers = { - enabled = ${boolToString nb.nodeMarkers.enable}, - icons = { - leaf = "${nb.nodeMarkers.icons.leaf}", - leaf_selected = "${nb.nodeMarkers.icons.leafSelected}", - branch = "${nb.nodeMarkers.icons.branch}", - }, - }, - - lsp = { - auto_attach = ${boolToString nb.lsp.autoAttach}, - -- preference = nil, -- TODO: convert list to lua table if not null - }, - - source_buffer = { - follow_node = ${boolToString nb.sourceBuffer.followNode}, - highlight = ${boolToString nb.sourceBuffer.highlight}, - reorient = "${nb.sourceBuffer.reorient}", - scrolloff = ${nilOrStr nb.sourceBuffer.scrolloff} - }, - - icons = { - File = "${cfg.navbuddy.icons.file}", - Module = "${cfg.navbuddy.icons.module}", - Namespace = "${cfg.navbuddy.icons.namespace}", - Package = "${cfg.navbuddy.icons.package}", - Class = "${cfg.navbuddy.icons.class}", - Method = "${cfg.navbuddy.icons.method}", - Property = "${cfg.navbuddy.icons.property}", - Field = "${cfg.navbuddy.icons.field}", - Constructor = "${cfg.navbuddy.icons.constructor}", - Enum = "${cfg.navbuddy.icons.enum}", - Interface = "${cfg.navbuddy.icons.interface}", - Function = "${cfg.navbuddy.icons.function}", - Variable = "${cfg.navbuddy.icons.variable}", - Constant = "${cfg.navbuddy.icons.constant}", - String = "${cfg.navbuddy.icons.string}", - Number = "${cfg.navbuddy.icons.number}", - Boolean = "${cfg.navbuddy.icons.boolean}", - Array = "${cfg.navbuddy.icons.array}", - Object = "${cfg.navbuddy.icons.object}", - Key = "${cfg.navbuddy.icons.key}", - Null = "${cfg.navbuddy.icons.null}", - EnumMember = "${cfg.navbuddy.icons.enumMember}", - Struct = "${cfg.navbuddy.icons.struct}", - Event = "${cfg.navbuddy.icons.event}", - Operator = "${cfg.navbuddy.icons.operator}", - TypeParameter = "${cfg.navbuddy.icons.typeParameter}" - }, - - -- make those configurable - use_default_mappings = ${toString (cfg.navbuddy.useDefaultMappings)}, - mappings = { - ["${cfg.navbuddy.mappings.close}"] = actions.close(), - ["${cfg.navbuddy.mappings.nextSibling}"] = actions.next_sibling(), - ["${cfg.navbuddy.mappings.previousSibling}"] = actions.previous_sibling(), - ["${cfg.navbuddy.mappings.close}"] = actions.parent(), - ["${cfg.navbuddy.mappings.children}"] = actions.children(), - ["${cfg.navbuddy.mappings.root}"] = actions.root(), - - ["${cfg.navbuddy.mappings.visualName}"] = actions.visual_name(), - ["${cfg.navbuddy.mappings.visualScope}"] = actions.visual_scope(), - - ["${cfg.navbuddy.mappings.yankName}"] = actions.yank_name(), - ["${cfg.navbuddy.mappings.yankScope}"] = actions.yank_scope(), - - ["${cfg.navbuddy.mappings.insertName}"] = actions.insert_name(), - ["${cfg.navbuddy.mappings.insertScope}"] = actions.insert_scope(), - - ["${cfg.navbuddy.mappings.appendName}"] = actions.append_name(), - ["${cfg.navbuddy.mappings.appendScope}"] = actions.append_scope(), - - ["${cfg.navbuddy.mappings.rename}"] = actions.rename(), - - ["${cfg.navbuddy.mappings.delete}"] = actions.delete(), - - ["${cfg.navbuddy.mappings.foldCreate}"] = actions.fold_create(), - ["${cfg.navbuddy.mappings.foldDelete}"] = actions.fold_delete(), - - ["${cfg.navbuddy.mappings.comment}"] = actions.comment(), - - ["${cfg.navbuddy.mappings.select}"] = actions.select(), - - ["${cfg.navbuddy.mappings.moveDown}"] = actions.move_down(), - ["${cfg.navbuddy.mappings.moveUp}"] = actions.move_up(), - - ["${cfg.navbuddy.mappings.telescope}"] = actions.telescope({ - layout_strategy = "horizontal", - layout_config = { - height = 0.60, - width = 0.75, - prompt_position = "top", - preview_width = 0.50 - }, - }), - - ["${cfg.navbuddy.mappings.help}"] = actions.help(), -- Open mappings help window - }, + ${lib.optionalString (cfg.source == "nvim-navic") '' + local navic = require("nvim-navic") + require("nvim-navic").setup { + highlight = true } + ''} + + ${lib.optionalString cfg.navbuddy.enable '' + local navbuddy = require("nvim-navbuddy") + local actions = require("nvim-navbuddy.actions") + navbuddy.setup { + window = { + border = "${nb.window.border}", -- "rounded", "double", "solid", "none" + size = "60%", + position = "50%", + scrolloff = ${(nilOrStr nb.window.scrolloff)}, + sections = { + left = { + size = "20%", + border = ${(nilOrStr nb.window.sections.left.border)}, + }, + + mid = { + size = "40%", + border = ${(nilOrStr nb.window.sections.mid.border)}, + }, + + right = { + border = ${(nilOrStr nb.window.sections.right.border)}, + preview = "leaf", + } + }, + }, + node_markers = { + enabled = ${boolToString nb.nodeMarkers.enable}, + icons = { + leaf = "${nb.nodeMarkers.icons.leaf}", + leaf_selected = "${nb.nodeMarkers.icons.leafSelected}", + branch = "${nb.nodeMarkers.icons.branch}", + }, + }, + + lsp = { + auto_attach = ${boolToString nb.lsp.autoAttach}, + -- preference = nil, -- TODO: convert list to lua table if not null + }, + + source_buffer = { + follow_node = ${boolToString nb.sourceBuffer.followNode}, + highlight = ${boolToString nb.sourceBuffer.highlight}, + reorient = "${nb.sourceBuffer.reorient}", + scrolloff = ${nilOrStr nb.sourceBuffer.scrolloff} + }, + + icons = { + File = "${cfg.navbuddy.icons.file}", + Module = "${cfg.navbuddy.icons.module}", + Namespace = "${cfg.navbuddy.icons.namespace}", + Package = "${cfg.navbuddy.icons.package}", + Class = "${cfg.navbuddy.icons.class}", + Method = "${cfg.navbuddy.icons.method}", + Property = "${cfg.navbuddy.icons.property}", + Field = "${cfg.navbuddy.icons.field}", + Constructor = "${cfg.navbuddy.icons.constructor}", + Enum = "${cfg.navbuddy.icons.enum}", + Interface = "${cfg.navbuddy.icons.interface}", + Function = "${cfg.navbuddy.icons.function}", + Variable = "${cfg.navbuddy.icons.variable}", + Constant = "${cfg.navbuddy.icons.constant}", + String = "${cfg.navbuddy.icons.string}", + Number = "${cfg.navbuddy.icons.number}", + Boolean = "${cfg.navbuddy.icons.boolean}", + Array = "${cfg.navbuddy.icons.array}", + Object = "${cfg.navbuddy.icons.object}", + Key = "${cfg.navbuddy.icons.key}", + Null = "${cfg.navbuddy.icons.null}", + EnumMember = "${cfg.navbuddy.icons.enumMember}", + Struct = "${cfg.navbuddy.icons.struct}", + Event = "${cfg.navbuddy.icons.event}", + Operator = "${cfg.navbuddy.icons.operator}", + TypeParameter = "${cfg.navbuddy.icons.typeParameter}" + }, + + -- make those configurable + use_default_mappings = ${toString (cfg.navbuddy.useDefaultMappings)}, + mappings = { + ["${cfg.navbuddy.mappings.close}"] = actions.close(), + ["${cfg.navbuddy.mappings.nextSibling}"] = actions.next_sibling(), + ["${cfg.navbuddy.mappings.previousSibling}"] = actions.previous_sibling(), + ["${cfg.navbuddy.mappings.close}"] = actions.parent(), + ["${cfg.navbuddy.mappings.children}"] = actions.children(), + ["${cfg.navbuddy.mappings.root}"] = actions.root(), + + ["${cfg.navbuddy.mappings.visualName}"] = actions.visual_name(), + ["${cfg.navbuddy.mappings.visualScope}"] = actions.visual_scope(), + + ["${cfg.navbuddy.mappings.yankName}"] = actions.yank_name(), + ["${cfg.navbuddy.mappings.yankScope}"] = actions.yank_scope(), + + ["${cfg.navbuddy.mappings.insertName}"] = actions.insert_name(), + ["${cfg.navbuddy.mappings.insertScope}"] = actions.insert_scope(), + + ["${cfg.navbuddy.mappings.appendName}"] = actions.append_name(), + ["${cfg.navbuddy.mappings.appendScope}"] = actions.append_scope(), + + ["${cfg.navbuddy.mappings.rename}"] = actions.rename(), + + ["${cfg.navbuddy.mappings.delete}"] = actions.delete(), + + ["${cfg.navbuddy.mappings.foldCreate}"] = actions.fold_create(), + ["${cfg.navbuddy.mappings.foldDelete}"] = actions.fold_delete(), + + ["${cfg.navbuddy.mappings.comment}"] = actions.comment(), + + ["${cfg.navbuddy.mappings.select}"] = actions.select(), + + ["${cfg.navbuddy.mappings.moveDown}"] = actions.move_down(), + ["${cfg.navbuddy.mappings.moveUp}"] = actions.move_up(), + + ["${cfg.navbuddy.mappings.telescope}"] = actions.telescope({ + layout_strategy = "horizontal", + layout_config = { + height = 0.60, + width = 0.75, + prompt_position = "top", + preview_width = 0.50 + }, + }), + + ["${cfg.navbuddy.mappings.help}"] = actions.help(), -- Open mappings help window + }, + } + ''} ''; }; } From de48713394e7feb254211ec84a0f481c6ce12b21 Mon Sep 17 00:00:00 2001 From: NotAShelf Date: Thu, 10 Aug 2023 20:24:30 +0300 Subject: [PATCH 7/8] fix: missing closing bracket when navbuddy is disabled --- lib/lua.nix | 1 - modules/ui/breadcrumbs/config.nix | 34 +++++++++++++++---------------- 2 files changed, 16 insertions(+), 19 deletions(-) diff --git a/lib/lua.nix b/lib/lua.nix index 1d4cdb9..c5c2ae5 100644 --- a/lib/lua.nix +++ b/lib/lua.nix @@ -13,7 +13,6 @@ else "'${value}'"; # convert an expression to lua - expToLua = exp: if builtins.isList exp then listToLuaTable exp # if list, convert to lua table diff --git a/modules/ui/breadcrumbs/config.nix b/modules/ui/breadcrumbs/config.nix index 730f493..0d988ca 100644 --- a/modules/ui/breadcrumbs/config.nix +++ b/modules/ui/breadcrumbs/config.nix @@ -3,42 +3,40 @@ lib, ... }: -with lib; with builtins; let + inherit (lib) optionalString boolToString mkIf optionals; + inherit (lib.nvim.lua) nullString; + cfg = config.vim.ui.breadcrumbs; nb = cfg.navbuddy; - - nilOrStr = v: - if v == null - then "nil" - else toString v; in { config = mkIf cfg.enable { vim.startPlugins = [ "nvim-lspconfig" ] - ++ lib.optionals (cfg.source == "nvim-navic") [ + ++ optionals (cfg.source == "nvim-navic") [ "nvim-navic" ] - ++ lib.optionals (config.vim.lsp.lspsaga.enable && cfg.source == "lspsaga") [ + ++ optionals (config.vim.lsp.lspsaga.enable && cfg.source == "lspsaga") [ "lspsaga" ] - ++ lib.optionals cfg.navbuddy.enable [ + ++ optionals cfg.navbuddy.enable [ "nvim-navbuddy" "nui-nvim" + "nvim-navic" ]; - vim.luaConfigRC.breadcrumbs = nvim.dag.entryAfter ["lspconfig"] '' + vim.luaConfigRC.breadcrumbs = lib.nvim.dag.entryAfter ["lspconfig"] '' - ${lib.optionalString (cfg.source == "nvim-navic") '' + ${optionalString (cfg.source == "nvim-navic") '' local navic = require("nvim-navic") require("nvim-navic").setup { highlight = true } ''} - ${lib.optionalString cfg.navbuddy.enable '' + ${optionalString cfg.navbuddy.enable '' local navbuddy = require("nvim-navbuddy") local actions = require("nvim-navbuddy.actions") navbuddy.setup { @@ -46,20 +44,20 @@ in { border = "${nb.window.border}", -- "rounded", "double", "solid", "none" size = "60%", position = "50%", - scrolloff = ${(nilOrStr nb.window.scrolloff)}, + scrolloff = ${(nullString nb.window.scrolloff)}, sections = { left = { size = "20%", - border = ${(nilOrStr nb.window.sections.left.border)}, + border = ${(nullString nb.window.sections.left.border)}, }, mid = { size = "40%", - border = ${(nilOrStr nb.window.sections.mid.border)}, + border = ${(nullString nb.window.sections.mid.border)}, }, right = { - border = ${(nilOrStr nb.window.sections.right.border)}, + border = ${(nullString nb.window.sections.right.border)}, preview = "leaf", } }, @@ -82,7 +80,7 @@ in { follow_node = ${boolToString nb.sourceBuffer.followNode}, highlight = ${boolToString nb.sourceBuffer.highlight}, reorient = "${nb.sourceBuffer.reorient}", - scrolloff = ${nilOrStr nb.sourceBuffer.scrolloff} + scrolloff = ${nullString nb.sourceBuffer.scrolloff} }, icons = { @@ -115,7 +113,7 @@ in { }, -- make those configurable - use_default_mappings = ${toString (cfg.navbuddy.useDefaultMappings)}, + use_default_mappings = ${boolToString cfg.navbuddy.useDefaultMappings}, mappings = { ["${cfg.navbuddy.mappings.close}"] = actions.close(), ["${cfg.navbuddy.mappings.nextSibling}"] = actions.next_sibling(), From b1184bab47a59506f7ff5d90ea0c86efb480167c Mon Sep 17 00:00:00 2001 From: NotAShelf Date: Fri, 11 Aug 2023 10:04:56 +0300 Subject: [PATCH 8/8] fix: warns due to types.string deprecation --- modules/debugger/nvim-dap/nvim-dap.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/debugger/nvim-dap/nvim-dap.nix b/modules/debugger/nvim-dap/nvim-dap.nix index b0fcb5e..8348d05 100644 --- a/modules/debugger/nvim-dap/nvim-dap.nix +++ b/modules/debugger/nvim-dap/nvim-dap.nix @@ -15,7 +15,7 @@ with lib; { sources = mkOption { default = {}; description = "List of debuggers to install"; - type = with types; attrsOf string; + type = with types; attrsOf str; }; mappings = {