diff --git a/plugins/by-name/conflict/default.nix b/plugins/by-name/conflict/default.nix new file mode 100644 index 00000000..4a848f2b --- /dev/null +++ b/plugins/by-name/conflict/default.nix @@ -0,0 +1,29 @@ +{ lib, ... }: +lib.nixvim.plugins.mkNeovimPlugin { + name = "conflict"; + package = "conflict-nvim"; + description = "A simple Neovim plugin to resolve merge conflicts with ease."; + + maintainers = [ lib.maintainers.jaredmontoya ]; + + dependencies = [ "git" ]; + + settingsExample = { + default_mappings = { + current = "co"; + incoming = "ct"; + both = "ca"; + base = "cb"; + none = "cn"; + next = "]e"; + prev = "[e"; + }; + show_actions = false; + disable_diagnostics = false; + highlights = { + current = "DiffChange"; + incoming = "DiffText"; + ancestor = "DiffDelete"; + }; + }; +} diff --git a/tests/test-sources/plugins/by-name/conflict/default.nix b/tests/test-sources/plugins/by-name/conflict/default.nix new file mode 100644 index 00000000..6f1a014f --- /dev/null +++ b/tests/test-sources/plugins/by-name/conflict/default.nix @@ -0,0 +1,55 @@ +{ + empty = { + plugins.conflict.enable = true; + }; + + defaults = { + plugins.conflict = { + enable = true; + + settings = { + default_mappings = { + current = "cc"; + incoming = "ci"; + both = "cb"; + base = "cB"; + none = false; + next = "]x"; + prev = "[x"; + }; + show_actions = true; + disable_diagnostics = true; + highlights = { + current = "DiffText"; + incoming = "DiffAdd"; + ancestor = "DiffChange"; + }; + }; + }; + }; + + example = { + plugins.conflict = { + enable = true; + + settings = { + default_mappings = { + current = "co"; + incoming = "ct"; + both = "ca"; + base = "cb"; + none = "cn"; + next = "]e"; + prev = "[e"; + }; + show_actions = false; + disable_diagnostics = false; + highlights = { + current = "DiffChange"; + incoming = "DiffText"; + ancestor = "DiffDelete"; + }; + }; + }; + }; +}