Compare commits

..

No commits in common. "ae3fd994472a1b95be5bf1ac9f70e2a1cdb1c1d4" and "b248b5af59ffdfaf9f6fdd400a114f60718f0b31" have entirely different histories.

7 changed files with 10 additions and 95 deletions

View file

@ -10,7 +10,6 @@
[typst-preview.nvim]: https://github.com/chomosuke/typst-preview.nvim [typst-preview.nvim]: https://github.com/chomosuke/typst-preview.nvim
[render-markdown.nvim]: https://github.com/MeanderingProgrammer/render-markdown.nvim [render-markdown.nvim]: https://github.com/MeanderingProgrammer/render-markdown.nvim
[yanky.nvim]: https://github.com/gbprod/yanky.nvim [yanky.nvim]: https://github.com/gbprod/yanky.nvim
[yazi.nvim]: https://github.com/mikavilpas/yazi.nvim
- Add [typst-preview.nvim] under - Add [typst-preview.nvim] under
`languages.typst.extensions.typst-preview-nvim`. `languages.typst.extensions.typst-preview-nvim`.
@ -47,11 +46,6 @@
- Add [yanky.nvim] to available plugins, under `vim.utility.yanky-nvim`. - Add [yanky.nvim] to available plugins, under `vim.utility.yanky-nvim`.
- Fix plugin `setupOpts` for yanky.nvim and assert if shada is configured as a
backend while shada is disabled in Neovim options.
- Add [yazi.nvim] as a companion plugin for Yazi, the terminal file manager.
[amadaluzia](https://github.com/amadaluzia): [amadaluzia](https://github.com/amadaluzia):
[haskell-tools.nvim]: https://github.com/MrcJkb/haskell-tools.nvim [haskell-tools.nvim]: https://github.com/MrcJkb/haskell-tools.nvim
@ -160,6 +154,7 @@
Inspiration from `vim.languages.clang.dap` implementation. Inspiration from `vim.languages.clang.dap` implementation.
- Add [leetcode.nvim] plugin under `vim.utility.leetcode-nvim`. - Add [leetcode.nvim] plugin under `vim.utility.leetcode-nvim`.
[nezia1](https://github.com/nezia1) [nezia1](https://github.com/nezia1)
- Add support for [nixd](https://github.com/nix-community/nixd) language server. - Add support for [nixd](https://github.com/nix-community/nixd) language server.
@ -170,7 +165,7 @@
available plugins, under `vim.utility.multicursors`. available plugins, under `vim.utility.multicursors`.
- Add [hydra.nvim](https://github.com/nvimtools/hydra.nvim) as dependency for - Add [hydra.nvim](https://github.com/nvimtools/hydra.nvim) as dependency for
`multicursors.nvim` and lazy loads by default. `multicursors.nvim` and lazy loads by default.
[folospior](https://github.com/folospior) [folospior](https://github.com/folospior)
- Fix plugin name for lsp/lspkind. - Fix plugin name for lsp/lspkind.
@ -185,8 +180,5 @@
[Libadoxon](https://github.com/Libadoxon) [Libadoxon](https://github.com/Libadoxon)
- Add [git-conflict](https://github.com/akinsho/git-conflict.nvim) plugin for - Add [git-conflict](https://github.com/akinsho/git-conflict.nvim) plugin for resolving git conflicts
resolving git conflicts - Add formatters for go: [gofmt](https://go.dev/blog/gofmt), [golines](https://github.com/segmentio/golines) and [gofumpt](https://github.com/mvdan/gofumpt)
- Add formatters for go: [gofmt](https://go.dev/blog/gofmt),
[golines](https://github.com/segmentio/golines) and
[gofumpt](https://github.com/mvdan/gofumpt)

View file

@ -7,7 +7,6 @@
./gestures ./gestures
./icon-picker ./icon-picker
./images ./images
./leetcode-nvim
./motion ./motion
./multicursors ./multicursors
./new-file-template ./new-file-template
@ -17,6 +16,6 @@
./telescope ./telescope
./wakatime ./wakatime
./yanky-nvim ./yanky-nvim
./yazi-nvim ./leetcode-nvim
]; ];
} }

View file

@ -11,7 +11,6 @@
cfg = config.vim.utility.yanky-nvim; cfg = config.vim.utility.yanky-nvim;
usingSqlite = cfg.setupOpts.ring.storage == "sqlite"; usingSqlite = cfg.setupOpts.ring.storage == "sqlite";
usingShada = cfg.setupOpts.ring.storage == "shada";
in { in {
config = mkIf cfg.enable { config = mkIf cfg.enable {
vim = { vim = {
@ -29,15 +28,5 @@ in {
require("yanky").setup(${toLuaObject cfg.setupOpts}); require("yanky").setup(${toLuaObject cfg.setupOpts});
''; '';
}; };
assertions = [
{
assertion = usingShada && ((config.vim.options.shada or "") == "");
message = ''
Yanky.nvim is configured to use 'shada' for the storage backend, but shada is disabled
in 'vim.options'. Please re-enable shada, or switch to a different backend.
'';
}
];
}; };
} }

View file

@ -1,14 +1,13 @@
{lib, ...}: let {lib, ...}: let
inherit (lib.options) mkOption mkEnableOption; inherit (lib.options) mkEnableOption mkOption;
inherit (lib.types) enum; inherit (lib.types) enum;
inherit (lib.nvim.types) mkPluginSetupOption;
in { in {
options.vim.utility.yanky-nvim = { options.vim.utility.yanky-nvim = {
enable = mkEnableOption '' enable = mkEnableOption ''
improved Yank and Put functionalities for Neovim [yanky-nvim] improved Yank and Put functionalities for Neovim [yanky-nvim]
''; '';
setupOpts = mkPluginSetupOption "yanky-nvim" { setupOpts = {
ring.storage = mkOption { ring.storage = mkOption {
type = enum ["shada" "sqlite" "memory"]; type = enum ["shada" "sqlite" "memory"];
default = "shada"; default = "shada";
@ -16,11 +15,11 @@ in {
description = '' description = ''
storage mode for ring values. storage mode for ring values.
- **shada**: this will save pesistantly using Neovim ShaDa feature. - shada: this will save pesistantly using Neovim ShaDa feature.
This means that history will be persisted between each session of Neovim. This means that history will be persisted between each session of Neovim.
- **memory**: each Neovim instance will have his own history and it will be - memory: each Neovim instance will have his own history and it will be
lost between sessions. lost between sessions.
- **sqlite**: more reliable than `shada`, requires `sqlite.lua` as a dependency. - sqlite: more reliable than `shada`, requires `sqlite.lua` as a dependency.
nvf will add this dependency to `PATH` automatically. nvf will add this dependency to `PATH` automatically.
''; '';
}; };

View file

@ -1,32 +0,0 @@
{
options,
config,
pkgs,
lib,
...
}: let
inherit (lib.modules) mkIf;
inherit (lib.nvim.binds) mkKeymap;
cfg = config.vim.utility.yazi-nvim;
keys = cfg.mappings;
inherit (options.vim.utility.yazi-nvim) mappings;
in {
config = mkIf cfg.enable {
vim = {
lazy.plugins."yazi.nvim" = {
package = pkgs.vimPlugins.yazi-nvim;
setupModule = "yazi";
inherit (cfg) setupOpts;
event = ["BufAdd" "VimEnter"];
keys = [
(mkKeymap "n" keys.openYazi "<cmd>Yazi<CR>" {desc = mappings.openYazi.description;})
(mkKeymap "n" keys.openYaziDir "<cmd>Yazi cwd<CR>" {desc = mappings.openYaziDir.description;})
(mkKeymap "n" keys.yaziToggle "<cmd>Yazi toggle<CR>" {desc = mappings.yaziToggle.description;})
];
};
};
};
}

View file

@ -1,6 +0,0 @@
{
imports = [
./config.nix
./yazi-nvim.nix
];
}

View file

@ -1,26 +0,0 @@
{lib, ...}: let
inherit (lib.options) mkEnableOption mkOption;
inherit (lib.types) bool;
inherit (lib.nvim.types) mkPluginSetupOption;
inherit (lib.nvim.binds) mkMappingOption;
in {
options.vim.utility.yazi-nvim = {
enable = mkEnableOption ''
companion plugin for the yazi terminal file manager [yazi-nvim]
'';
mappings = {
openYazi = mkMappingOption "Open yazi at the current file [yazi.nvim]" "<leader>-";
openYaziDir = mkMappingOption "Open the file manager in nvim's working directory [yazi.nvim]" "<leader>cw";
yaziToggle = mkMappingOption "Resume the last yazi session [yazi.nvim]" "<c-up>";
};
setupOpts = mkPluginSetupOption "yazi-nvim" {
open_for_directories = mkOption {
type = bool;
default = false;
description = "Whether to open Yazi instead of netrw";
};
};
};
}