mirror of
https://github.com/NotAShelf/nvf.git
synced 2025-09-06 02:11:33 +00:00
feat: apply new module format to utility plugins
new file: modules/utility/binds/cheatsheet/cheatsheet.nix new file: modules/utility/binds/cheatsheet/config.nix modified: modules/utility/binds/cheatsheet/default.nix modified: modules/utility/binds/default.nix new file: modules/utility/binds/which-key/config.nix modified: modules/utility/binds/which-key/default.nix new file: modules/utility/binds/which-key/which-key.nix renamed: modules/utility/colorizer.nix -> modules/utility/colorizer/colorizer.nix new file: modules/utility/colorizer/config.nix new file: modules/utility/colorizer/default.nix modified: modules/utility/default.nix modified: modules/utility/gestures/default.nix renamed: modules/utility/gestures/gesture-nvim.nix -> modules/utility/gestures/gesture-nvim/config.nix new file: modules/utility/gestures/gesture-nvim/default.nix new file: modules/utility/gestures/gesture-nvim/gesture-nvim.nix renamed: modules/utility/icon-picker.nix -> modules/utility/icon-picker/config.nix new file: modules/utility/icon-picker/default.nix new file: modules/utility/icon-picker/icon-picker.nix new file: modules/utility/telescope/config.nix modified: modules/utility/telescope/default.nix new file: modules/utility/telescope/telescope.nix renamed: modules/utility/venn.nix -> modules/utility/venn/config.nix new file: modules/utility/venn/default.nix new file: modules/utility/venn/venn.nix
This commit is contained in:
parent
940dfcdef9
commit
729276c4c5
26 changed files with 503 additions and 413 deletions
14
modules/utility/binds/cheatsheet/cheatsheet.nix
Normal file
14
modules/utility/binds/cheatsheet/cheatsheet.nix
Normal file
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
with builtins; let
|
||||
cfg = config.vim.binds.cheatsheet;
|
||||
in {
|
||||
options.vim.binds.cheatsheet = {
|
||||
enable = mkEnableOption "Searchable cheatsheet for nvim using telescope";
|
||||
};
|
||||
}
|
18
modules/utility/binds/cheatsheet/config.nix
Normal file
18
modules/utility/binds/cheatsheet/config.nix
Normal file
|
@ -0,0 +1,18 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
with builtins; let
|
||||
cfg = config.vim.binds.cheatsheet;
|
||||
in {
|
||||
config = mkIf (cfg.enable) {
|
||||
vim.startPlugins = ["cheatsheet-nvim"];
|
||||
|
||||
vim.luaConfigRC.cheaetsheet-nvim = nvim.dag.entryAnywhere ''
|
||||
require('cheatsheet').setup({})
|
||||
'';
|
||||
};
|
||||
}
|
|
@ -1,22 +1,6 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
with builtins; let
|
||||
cfg = config.vim.binds.cheatsheet;
|
||||
in {
|
||||
options.vim.binds.cheatsheet = {
|
||||
enable = mkEnableOption "Searchable cheatsheet for nvim using telescope";
|
||||
};
|
||||
|
||||
config = mkIf (cfg.enable) {
|
||||
vim.startPlugins = ["cheatsheet-nvim"];
|
||||
|
||||
vim.luaConfigRC.cheaetsheet-nvim = nvim.dag.entryAnywhere ''
|
||||
require('cheatsheet').setup({})
|
||||
'';
|
||||
};
|
||||
_: {
|
||||
imports = [
|
||||
./cheatsheet.nix
|
||||
./config.nix
|
||||
];
|
||||
}
|
||||
|
|
|
@ -1,9 +1,4 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
_: {
|
||||
imports = [
|
||||
./which-key
|
||||
./cheatsheet
|
||||
|
|
115
modules/utility/binds/which-key/config.nix
Normal file
115
modules/utility/binds/which-key/config.nix
Normal file
|
@ -0,0 +1,115 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
with builtins; let
|
||||
cfg = config.vim.binds.whichKey;
|
||||
in {
|
||||
config = mkIf (cfg.enable) {
|
||||
vim.startPlugins = ["which-key"];
|
||||
|
||||
vim.luaConfigRC.whichkey = nvim.dag.entryAnywhere ''
|
||||
local wk = require("which-key")
|
||||
wk.setup {}
|
||||
|
||||
|
||||
wk.register({
|
||||
key_labels = {
|
||||
["<space>"] = "SPACE",
|
||||
["<leader>"] = "SPACE",
|
||||
["<cr>"] = "RETURN",
|
||||
["<tab>"] = "TAB",
|
||||
},
|
||||
|
||||
${
|
||||
if config.vim.tabline.nvimBufferline.enable
|
||||
then ''
|
||||
-- Buffer
|
||||
["<leader>b"] = { name = "+Buffer" },
|
||||
["<leader>bm"] = { name = "BufferLineMove" },
|
||||
["<leader>bs"] = { name = "BufferLineSort" },
|
||||
["<leader>bsi"] = { name = "BufferLineSortById" },
|
||||
|
||||
''
|
||||
else ""
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.telescope.enable
|
||||
then ''
|
||||
["<leader>f"] = { name = "+Telescope" },
|
||||
-- Telescope
|
||||
["<leader>fl"] = { name = "Telescope LSP" },
|
||||
["<leader>fm"] = { name = "Cellular Automaton" }, -- TODO: mvoe this to its own parent group
|
||||
["<leader>fv"] = { name = "Telescope Git" },
|
||||
["<leader>fvc"] = { name = "Commits" },
|
||||
''
|
||||
else ""
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.lsp.trouble.enable
|
||||
then ''
|
||||
-- Trouble
|
||||
["<leader>lw"] = { name = "Workspace" },
|
||||
["<leader>x"] = { name = "+Trouble" }, -- TODO: move all trouble binds to the same parent group
|
||||
["<leader>l"] = { name = "+Trouble" },
|
||||
''
|
||||
else ""
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.lsp.nvimCodeActionMenu.enable
|
||||
then ''
|
||||
-- Parent Groups
|
||||
["<leader>c"] = { name = "+CodeAction" },
|
||||
''
|
||||
else ""
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.minimap.codewindow.enable || config.vim.minimap.minimap-vim.enable
|
||||
then ''
|
||||
-- Minimap
|
||||
["<leader>m"] = { name = "+Minimap" }, -- TODO: remap both minimap plugins' keys to be the same
|
||||
''
|
||||
else ""
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.notes.mind-nvim.enable || config.vim.notes.obsidian.enable || config.vim.notes.orgmode.enable
|
||||
then ''
|
||||
-- Notes
|
||||
["<leader>o"] = { name = "+Notes" },
|
||||
-- TODO: options for other note taking plugins and their individual binds
|
||||
-- TODO: move all note-taker binds under leader + o
|
||||
''
|
||||
else ""
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.filetree.nvimTreeLua.enable
|
||||
then ''
|
||||
-- NvimTree
|
||||
["<leader>t"] = { name = "+NvimTree" },
|
||||
''
|
||||
else ""
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.git.gitsigns.enable
|
||||
then ''
|
||||
-- Git
|
||||
["<leader>g"] = { name = "+Gitsigns" },
|
||||
''
|
||||
else ""
|
||||
}
|
||||
|
||||
})
|
||||
|
||||
'';
|
||||
};
|
||||
}
|
|
@ -1,118 +1,6 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
with builtins; let
|
||||
cfg = config.vim.binds.whichKey;
|
||||
in {
|
||||
options.vim.binds.whichKey = {
|
||||
enable = mkEnableOption "which-key menu";
|
||||
};
|
||||
|
||||
config = mkIf (cfg.enable) {
|
||||
vim.startPlugins = ["which-key"];
|
||||
|
||||
vim.luaConfigRC.whichkey = nvim.dag.entryAnywhere ''
|
||||
require("which-key").setup {}
|
||||
|
||||
local wk = require("which-key")
|
||||
wk.register({
|
||||
key_labels = {
|
||||
["<space>"] = "SPACE",
|
||||
["<leader>"] = "SPACE",
|
||||
["<cr>"] = "RETURN",
|
||||
["<tab>"] = "TAB",
|
||||
},
|
||||
|
||||
${
|
||||
if config.vim.tabline.nvimBufferline.enable
|
||||
then ''
|
||||
-- Buffer
|
||||
["<leader>b"] = { name = "+Buffer" },
|
||||
["<leader>bm"] = { name = "BufferLineMove" },
|
||||
["<leader>bs"] = { name = "BufferLineSort" },
|
||||
["<leader>bsi"] = { name = "BufferLineSortById" },
|
||||
|
||||
''
|
||||
else ""
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.telescope.enable
|
||||
then ''
|
||||
["<leader>f"] = { name = "+Telescope" },
|
||||
-- Telescope
|
||||
["<leader>fl"] = { name = "Telescope LSP" },
|
||||
["<leader>fm"] = { name = "Cellular Automaton" }, -- TODO: mvoe this to its own parent group
|
||||
["<leader>fv"] = { name = "Telescope Git" },
|
||||
["<leader>fvc"] = { name = "Commits" },
|
||||
''
|
||||
else ""
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.lsp.trouble.enable
|
||||
then ''
|
||||
-- Trouble
|
||||
["<leader>lw"] = { name = "Workspace" },
|
||||
["<leader>x"] = { name = "+Trouble" }, -- TODO: move all trouble binds to the same parent group
|
||||
["<leader>l"] = { name = "+Trouble" },
|
||||
''
|
||||
else ""
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.lsp.nvimCodeActionMenu.enable
|
||||
then ''
|
||||
-- Parent Groups
|
||||
["<leader>c"] = { name = "+CodeAction" },
|
||||
''
|
||||
else ""
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.minimap.codewindow.enable || config.vim.minimap.minimap-vim.enable
|
||||
then ''
|
||||
-- Minimap
|
||||
["<leader>m"] = { name = "+Minimap" },
|
||||
''
|
||||
else ""
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.notes.mind-nvim.enable || config.vim.notes.obsidian.enable || config.vim.notes.orgmode.enable
|
||||
then ''
|
||||
-- Notes
|
||||
["<leader>o"] = { name = "+Notes" },
|
||||
-- TODO: options for other note taking plugins and their individual binds
|
||||
-- TODO: move all note-taker binds under leader + o
|
||||
''
|
||||
else ""
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.filetree.nvimTreeLua.enable
|
||||
then ''
|
||||
-- NvimTree
|
||||
["<leader>t"] = { name = "+NvimTree" },
|
||||
''
|
||||
else ""
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.git.gitsigns.enable
|
||||
then ''
|
||||
-- Git
|
||||
["<leader>g"] = { name = "+Gitsigns" },
|
||||
''
|
||||
else ""
|
||||
}
|
||||
|
||||
})
|
||||
|
||||
'';
|
||||
};
|
||||
_: {
|
||||
imports = [
|
||||
./which-key.nix
|
||||
./config.nix
|
||||
];
|
||||
}
|
||||
|
|
14
modules/utility/binds/which-key/which-key.nix
Normal file
14
modules/utility/binds/which-key/which-key.nix
Normal file
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
with builtins; let
|
||||
cfg = config.vim.binds.whichKey;
|
||||
in {
|
||||
options.vim.binds.whichKey = {
|
||||
enable = mkEnableOption "which-key menu";
|
||||
};
|
||||
}
|
|
@ -11,14 +11,4 @@ in {
|
|||
options.vim.utility.colorizer = {
|
||||
enable = mkEnableOption "ccc color picker for neovim";
|
||||
};
|
||||
|
||||
config = mkIf (cfg.enable) {
|
||||
vim.startPlugins = [
|
||||
"colorizer"
|
||||
];
|
||||
|
||||
vim.configRC.ccc =
|
||||
nvim.dag.entryAnywhere ''
|
||||
'';
|
||||
};
|
||||
}
|
16
modules/utility/colorizer/config.nix
Normal file
16
modules/utility/colorizer/config.nix
Normal file
|
@ -0,0 +1,16 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
with builtins; let
|
||||
cfg = config.vim.utility.colorizer;
|
||||
in {
|
||||
config = mkIf (cfg.enable) {
|
||||
vim.startPlugins = [
|
||||
"colorizer"
|
||||
];
|
||||
};
|
||||
}
|
6
modules/utility/colorizer/default.nix
Normal file
6
modules/utility/colorizer/default.nix
Normal file
|
@ -0,0 +1,6 @@
|
|||
_: {
|
||||
imports = [
|
||||
./colorizer.nix
|
||||
./config.nix
|
||||
];
|
||||
}
|
|
@ -3,8 +3,9 @@ _: {
|
|||
./binds
|
||||
./gestures
|
||||
./telescope
|
||||
./colorizer.nix
|
||||
./venn.nix
|
||||
./icon-picker.nix
|
||||
./colorizer
|
||||
./icon-picker
|
||||
./telescope
|
||||
./venn
|
||||
];
|
||||
}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
_: {
|
||||
imports = [
|
||||
./gesture-nvim.nix
|
||||
./gesture-nvim
|
||||
];
|
||||
}
|
||||
|
|
|
@ -8,10 +8,6 @@ with lib;
|
|||
with builtins; let
|
||||
cfg = config.vim.gestures.gesture-nvim;
|
||||
in {
|
||||
options.vim.gestures.gesture-nvim = {
|
||||
enable = mkEnableOption "Enable GitHub Copilot";
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
vim.startPlugins = ["gesture-nvim"];
|
||||
|
6
modules/utility/gestures/gesture-nvim/default.nix
Normal file
6
modules/utility/gestures/gesture-nvim/default.nix
Normal file
|
@ -0,0 +1,6 @@
|
|||
_: {
|
||||
imports = [
|
||||
./gesture-nvim.nix
|
||||
./config.nix
|
||||
];
|
||||
}
|
14
modules/utility/gestures/gesture-nvim/gesture-nvim.nix
Normal file
14
modules/utility/gestures/gesture-nvim/gesture-nvim.nix
Normal file
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
with builtins; let
|
||||
cfg = config.vim.gestures.gesture-nvim;
|
||||
in {
|
||||
options.vim.gestures.gesture-nvim = {
|
||||
enable = mkEnableOption "Enable gesture-nvim plugin";
|
||||
};
|
||||
}
|
|
@ -8,10 +8,6 @@ with lib;
|
|||
with builtins; let
|
||||
cfg = config.vim.utility.icon-picker;
|
||||
in {
|
||||
options.vim.utility.icon-picker = {
|
||||
enable = mkEnableOption "Nerdfonts icon picker for nvim";
|
||||
};
|
||||
|
||||
config = mkIf (cfg.enable) {
|
||||
vim.startPlugins = [
|
||||
"icon-picker-nvim"
|
6
modules/utility/icon-picker/default.nix
Normal file
6
modules/utility/icon-picker/default.nix
Normal file
|
@ -0,0 +1,6 @@
|
|||
_: {
|
||||
imports = [
|
||||
./icon-picker.nix
|
||||
./config.nix
|
||||
];
|
||||
}
|
14
modules/utility/icon-picker/icon-picker.nix
Normal file
14
modules/utility/icon-picker/icon-picker.nix
Normal file
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
with builtins; let
|
||||
cfg = config.vim.utility.icon-picker;
|
||||
in {
|
||||
options.vim.utility.icon-picker = {
|
||||
enable = mkEnableOption "Nerdfonts icon picker for nvim";
|
||||
};
|
||||
}
|
86
modules/utility/telescope/config.nix
Normal file
86
modules/utility/telescope/config.nix
Normal file
|
@ -0,0 +1,86 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
with builtins; let
|
||||
cfg = config.vim.telescope;
|
||||
in {
|
||||
config = mkIf (cfg.enable) {
|
||||
vim.startPlugins = [
|
||||
"telescope"
|
||||
];
|
||||
|
||||
vim.nnoremap =
|
||||
{
|
||||
"<leader>ff" = "<cmd> Telescope find_files<CR>";
|
||||
"<leader>fg" = "<cmd> Telescope live_grep<CR>";
|
||||
"<leader>fb" = "<cmd> Telescope buffers<CR>";
|
||||
"<leader>fh" = "<cmd> Telescope help_tags<CR>";
|
||||
"<leader>ft" = "<cmd> Telescope<CR>";
|
||||
|
||||
"<leader>fvcw" = "<cmd> Telescope git_commits<CR>";
|
||||
"<leader>fvcb" = "<cmd> Telescope git_bcommits<CR>";
|
||||
"<leader>fvb" = "<cmd> Telescope git_branches<CR>";
|
||||
"<leader>fvs" = "<cmd> Telescope git_status<CR>";
|
||||
"<leader>fvx" = "<cmd> Telescope git_stash<CR>";
|
||||
}
|
||||
// (
|
||||
if config.vim.lsp.enable
|
||||
then {
|
||||
"<leader>flsb" = "<cmd> Telescope lsp_document_symbols<CR>";
|
||||
"<leader>flsw" = "<cmd> Telescope lsp_workspace_symbols<CR>";
|
||||
|
||||
"<leader>flr" = "<cmd> Telescope lsp_references<CR>";
|
||||
"<leader>fli" = "<cmd> Telescope lsp_implementations<CR>";
|
||||
"<leader>flD" = "<cmd> Telescope lsp_definitions<CR>";
|
||||
"<leader>flt" = "<cmd> Telescope lsp_type_definitions<CR>";
|
||||
"<leader>fld" = "<cmd> Telescope diagnostics<CR>";
|
||||
}
|
||||
else {}
|
||||
)
|
||||
// (
|
||||
if config.vim.treesitter.enable
|
||||
then {
|
||||
"<leader>fs" = "<cmd> Telescope treesitter<CR>";
|
||||
}
|
||||
else {}
|
||||
);
|
||||
|
||||
vim.luaConfigRC.telescope = nvim.dag.entryAnywhere ''
|
||||
local telescope = require('telescope')
|
||||
telescope.setup {
|
||||
defaults = {
|
||||
vimgrep_arguments = {
|
||||
"${pkgs.ripgrep}/bin/rg",
|
||||
"--color=never",
|
||||
"--no-heading",
|
||||
"--with-filename",
|
||||
"--line-number",
|
||||
"--column",
|
||||
"--smart-case"
|
||||
},
|
||||
pickers = {
|
||||
find_command = {
|
||||
"${pkgs.fd}/bin/fd",
|
||||
},
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.ui.noice.enable
|
||||
then "telescope.load_extension('noice')"
|
||||
else null
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.notify.nvim-notify.enable
|
||||
then "telescope.load_extension('notify')"
|
||||
else null
|
||||
}
|
||||
'';
|
||||
};
|
||||
}
|
|
@ -1,90 +1,6 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
with builtins; let
|
||||
cfg = config.vim.telescope;
|
||||
in {
|
||||
options.vim.telescope = {
|
||||
enable = mkEnableOption "enable telescope";
|
||||
};
|
||||
|
||||
config = mkIf (cfg.enable) {
|
||||
vim.startPlugins = [
|
||||
"telescope"
|
||||
];
|
||||
|
||||
vim.nnoremap =
|
||||
{
|
||||
"<leader>ff" = "<cmd> Telescope find_files<CR>";
|
||||
"<leader>fg" = "<cmd> Telescope live_grep<CR>";
|
||||
"<leader>fb" = "<cmd> Telescope buffers<CR>";
|
||||
"<leader>fh" = "<cmd> Telescope help_tags<CR>";
|
||||
"<leader>ft" = "<cmd> Telescope<CR>";
|
||||
|
||||
"<leader>fvcw" = "<cmd> Telescope git_commits<CR>";
|
||||
"<leader>fvcb" = "<cmd> Telescope git_bcommits<CR>";
|
||||
"<leader>fvb" = "<cmd> Telescope git_branches<CR>";
|
||||
"<leader>fvs" = "<cmd> Telescope git_status<CR>";
|
||||
"<leader>fvx" = "<cmd> Telescope git_stash<CR>";
|
||||
}
|
||||
// (
|
||||
if config.vim.lsp.enable
|
||||
then {
|
||||
"<leader>flsb" = "<cmd> Telescope lsp_document_symbols<CR>";
|
||||
"<leader>flsw" = "<cmd> Telescope lsp_workspace_symbols<CR>";
|
||||
|
||||
"<leader>flr" = "<cmd> Telescope lsp_references<CR>";
|
||||
"<leader>fli" = "<cmd> Telescope lsp_implementations<CR>";
|
||||
"<leader>flD" = "<cmd> Telescope lsp_definitions<CR>";
|
||||
"<leader>flt" = "<cmd> Telescope lsp_type_definitions<CR>";
|
||||
"<leader>fld" = "<cmd> Telescope diagnostics<CR>";
|
||||
}
|
||||
else {}
|
||||
)
|
||||
// (
|
||||
if config.vim.treesitter.enable
|
||||
then {
|
||||
"<leader>fs" = "<cmd> Telescope treesitter<CR>";
|
||||
}
|
||||
else {}
|
||||
);
|
||||
|
||||
vim.luaConfigRC.telescope = nvim.dag.entryAnywhere ''
|
||||
local telescope = require('telescope')
|
||||
telescope.setup {
|
||||
defaults = {
|
||||
vimgrep_arguments = {
|
||||
"${pkgs.ripgrep}/bin/rg",
|
||||
"--color=never",
|
||||
"--no-heading",
|
||||
"--with-filename",
|
||||
"--line-number",
|
||||
"--column",
|
||||
"--smart-case"
|
||||
},
|
||||
pickers = {
|
||||
find_command = {
|
||||
"${pkgs.fd}/bin/fd",
|
||||
},
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.ui.noice.enable
|
||||
then "telescope.load_extension('noice')"
|
||||
else null
|
||||
}
|
||||
|
||||
${
|
||||
if config.vim.notify.nvim-notify.enable
|
||||
then "telescope.load_extension('notify')"
|
||||
else null
|
||||
}
|
||||
'';
|
||||
};
|
||||
_: {
|
||||
imports = [
|
||||
./telescope.nix
|
||||
./config.nix
|
||||
];
|
||||
}
|
||||
|
|
14
modules/utility/telescope/telescope.nix
Normal file
14
modules/utility/telescope/telescope.nix
Normal file
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
with builtins; let
|
||||
cfg = config.vim.telescope;
|
||||
in {
|
||||
options.vim.telescope = {
|
||||
enable = mkEnableOption "enable telescope";
|
||||
};
|
||||
}
|
|
@ -8,10 +8,6 @@ with lib;
|
|||
with builtins; let
|
||||
cfg = config.vim.utility.venn-nvim;
|
||||
in {
|
||||
options.vim.utility.venn-nvim = {
|
||||
enable = mkEnableOption "draw ASCII diagrams in Neovim";
|
||||
};
|
||||
|
||||
config = mkIf (cfg.enable) {
|
||||
vim.startPlugins = [
|
||||
"venn-nvim"
|
6
modules/utility/venn/default.nix
Normal file
6
modules/utility/venn/default.nix
Normal file
|
@ -0,0 +1,6 @@
|
|||
_: {
|
||||
imports = [
|
||||
./config.nix
|
||||
./venn.nix
|
||||
];
|
||||
}
|
14
modules/utility/venn/venn.nix
Normal file
14
modules/utility/venn/venn.nix
Normal file
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
with builtins; let
|
||||
cfg = config.vim.utility.venn-nvim;
|
||||
in {
|
||||
options.vim.utility.venn-nvim = {
|
||||
enable = mkEnableOption "draw ASCII diagrams in Neovim";
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue