1
0
Fork 0
mirror of https://github.com/NotAShelf/neovim-flake.git synced 2024-12-25 07:59:48 +01:00

treewide: rename function defaultAttributes to pushDownDefault

This commit is contained in:
Frothy 2024-02-25 22:52:21 -05:00
parent 9a7087e53c
commit 4716fd731f
13 changed files with 25 additions and 25 deletions
lib
modules
filetree/nvimtree
git
lsp
nvim-code-action-menu
trouble
minimap
codewindow
minimap-vim
notes
mind-nvim
obsidian
orgmode
tabline/nvim-bufferline
utility
preview/glow
telescope

View file

@ -68,7 +68,7 @@ in
mkSetLuaBinding = binding: action:
mkLuaBinding binding.value action binding.description;
defaultAttributes = attr: self.mapAttrs (name: value: self.mkDefault value) attr;
pushDownDefault = attr: self.mapAttrs (name: value: self.mkDefault value) attr;
# For forward compatibility.
literalExpression = super.literalExpression or super.literalExample;

View file

@ -4,7 +4,7 @@
pkgs,
...
}: let
inherit (lib) mkIf mkMerge mkBinding nvim boolToString defaultAttributes;
inherit (lib) mkIf mkMerge mkBinding nvim boolToString pushDownDefault;
cfg = config.vim.filetree.nvimTree;
self = import ./nvimtree.nix {
@ -23,7 +23,7 @@ in {
(mkBinding cfg.mappings.focus ":NvimTreeFocus<cr>" mappings.focus.description)
];
vim.binds.whichKey.register = defaultAttributes {
vim.binds.whichKey.register = pushDownDefault {
"<leader>t" = "+NvimTree";
};

View file

@ -4,7 +4,7 @@
...
}: let
inherit (builtins) toJSON;
inherit (lib) addDescriptionsToMappings mkIf mkMerge mkSetExprBinding mkSetLuaBinding nvim defaultAttributes;
inherit (lib) addDescriptionsToMappings mkIf mkMerge mkSetExprBinding mkSetLuaBinding nvim pushDownDefault;
cfg = config.vim.git;
@ -61,7 +61,7 @@ in {
(mkSetLuaBinding gsMappings.resetHunk "function() package.loaded.gitsigns.reset_hunk {vim.fn.line('.'), vim.fn.line('v')} end")
];
vim.binds.whichKey.register = defaultAttributes {
vim.binds.whichKey.register = pushDownDefault {
"<leader>g" = "+Gitsigns";
};

View file

@ -3,7 +3,7 @@
lib,
...
}: let
inherit (lib) addDescriptionsToMappings mkIf mkSetBinding nvim defaultAttributes;
inherit (lib) addDescriptionsToMappings mkIf mkSetBinding nvim pushDownDefault;
cfg = config.vim.lsp;
@ -17,7 +17,7 @@ in {
vim.maps.normal = mkSetBinding mappings.open ":CodeActionMenu<CR>";
vim.binds.whichKey.register = defaultAttributes {
vim.binds.whichKey.register = pushDownDefault {
"<leader>c" = "+CodeAction";
};

View file

@ -3,7 +3,7 @@
lib,
...
}: let
inherit (lib) addDescriptionsToMappings mkIf mkMerge mkSetBinding nvim defaultAttributes;
inherit (lib) addDescriptionsToMappings mkIf mkMerge mkSetBinding nvim pushDownDefault;
cfg = config.vim.lsp;
@ -24,7 +24,7 @@ in {
(mkSetBinding mappings.locList "<cmd>TroubleToggle loclist<CR>")
];
vim.binds.whichKey.register = defaultAttributes {
vim.binds.whichKey.register = pushDownDefault {
"<leader>l" = "Trouble";
"<leader>x" = "+Trouble";
"<leader>lw" = "Workspace";

View file

@ -3,7 +3,7 @@
lib,
...
}: let
inherit (lib) addDescriptionsToMappings mkIf mkMerge mkSetLuaBinding nvim defaultAttributes;
inherit (lib) addDescriptionsToMappings mkIf mkMerge mkSetLuaBinding nvim pushDownDefault;
cfg = config.vim.minimap.codewindow;
@ -24,7 +24,7 @@ in {
(mkSetLuaBinding mappings.toggleFocus "require('codewindow').toggle_focus")
];
vim.binds.whichKey.register = defaultAttributes {
vim.binds.whichKey.register = pushDownDefault {
"<leader>m" = "+Minimap";
};

View file

@ -4,7 +4,7 @@
lib,
...
}: let
inherit (lib) mkIf defaultAttributes;
inherit (lib) mkIf pushDownDefault;
cfg = config.vim.minimap.minimap-vim;
in {
@ -14,7 +14,7 @@ in {
"minimap-vim"
];
vim.binds.whichKey.register = defaultAttributes {
vim.binds.whichKey.register = pushDownDefault {
"<leader>m" = "+Minimap";
};
};

View file

@ -3,7 +3,7 @@
lib,
...
}: let
inherit (lib) mkIf nvim defaultAttributes;
inherit (lib) mkIf nvim pushDownDefault;
cfg = config.vim.notes.mind-nvim;
in {
@ -18,7 +18,7 @@ in {
"<leader>oc" = {action = ":MindClose<CR>";};
};
vim.binds.whichKey.register = defaultAttributes {
vim.binds.whichKey.register = pushDownDefault {
"<leader>o" = "+Notes";
};

View file

@ -3,7 +3,7 @@
lib,
...
}: let
inherit (lib) mkIf nvim defaultAttributes;
inherit (lib) mkIf nvim pushDownDefault;
cfg = config.vim.notes.obsidian;
auto = config.vim.autocomplete;
@ -15,7 +15,7 @@ in {
"tabular"
];
vim.binds.whichKey.register = defaultAttributes {
vim.binds.whichKey.register = pushDownDefault {
"<leader>o" = "+Notes";
};

View file

@ -3,7 +3,7 @@
lib,
...
}: let
inherit (lib) mkIf mkMerge nvim defaultAttributes;
inherit (lib) mkIf mkMerge nvim pushDownDefault;
cfg = config.vim.notes.orgmode;
in {
@ -13,7 +13,7 @@ in {
"orgmode-nvim"
];
vim.binds.whichKey.register = defaultAttributes {
vim.binds.whichKey.register = pushDownDefault {
"<leader>o" = "+Notes";
};

View file

@ -3,7 +3,7 @@
lib,
...
}: let
inherit (lib) mkIf mkMerge mkLuaBinding mkBinding nvim defaultAttributes;
inherit (lib) mkIf mkMerge mkLuaBinding mkBinding nvim pushDownDefault;
cfg = config.vim.tabline.nvimBufferline;
self = import ./nvim-bufferline.nix {
@ -40,7 +40,7 @@ in {
(mkBinding cfg.mappings.movePrevious ":BufferLineMovePrev<CR>" mappings.movePrevious.description)
];
vim.binds.whichKey.register = defaultAttributes {
vim.binds.whichKey.register = pushDownDefault {
"<leader>b" = "+Buffer";
"<leader>bm" = "BufferLineMove";
"<leader>bs" = "BufferLineSort";

View file

@ -4,7 +4,7 @@
lib,
...
}: let
inherit (lib) nvim mkIf mkMerge mkBinding defaultAttributes;
inherit (lib) nvim mkIf mkMerge mkBinding pushDownDefault;
cfg = config.vim.utility.preview.glow;
self = import ./glow.nix {
@ -19,7 +19,7 @@ in {
(mkBinding cfg.mappings.openPreview ":Glow<CR>" mappings.openPreview.description)
];
vim.binds.whichKey.register = defaultAttributes {
vim.binds.whichKey.register = pushDownDefault {
"<leader>pm" = "+Preview Markdown";
};

View file

@ -4,7 +4,7 @@
lib,
...
}: let
inherit (lib) addDescriptionsToMappings mkIf mkMerge mkSetBinding nvim defaultAttributes;
inherit (lib) addDescriptionsToMappings mkIf mkMerge mkSetBinding nvim pushDownDefault;
cfg = config.vim.telescope;
self = import ./telescope.nix {inherit lib;};
@ -52,7 +52,7 @@ in {
)
];
vim.binds.whichKey.register = defaultAttributes {
vim.binds.whichKey.register = pushDownDefault {
"<leader>f" = "+Telescope";
"<leader>fl" = "Telescope LSP";
"<leader>fm" = "Cellular Automaton";