Skip to content

Commit 23b1960

Browse files
committed
feature(plugins): Add gitlineage
1 parent f6d58ad commit 23b1960

File tree

5 files changed

+40
-0
lines changed

5 files changed

+40
-0
lines changed

config/autocmds.nix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
{name = "resize";}
66
{name = "neotree";}
77
{name = "filetypes";}
8+
{name = "keybinds";}
89
];
910
vim.autocmds = [
1011
{

config/base.nix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@
8585
extraLuaFiles =
8686
[
8787
./lua/yankAndPaste.lua
88+
./lua/gitlineage.lua
8889
./lua/dap.lua
8990
]
9091
++ config'.additionalLuaConfigFiles;

config/editor/misc.nix

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,17 @@
2626
hash = "sha256-CqMvJmgjsvs3oTQX4WWJssF0zNJ7cDe9b0CcRP/ALpY=";
2727
};
2828
};
29+
gitlineage = pkgs.vimUtils.buildVimPlugin {
30+
pname = "gitlineage.nvim";
31+
version = "06.02.2026";
32+
33+
src = pkgs.fetchFromGitHub {
34+
owner = "LionyxML";
35+
repo = "gitlineage.nvim";
36+
rev = "02896814949798551238235cc66693f1c143626d";
37+
hash = "sha256-BGCE/SosircJu9JDz92JKlMgNw7CEl6BeIDDFEvGWFs=";
38+
};
39+
};
2940
in {
3041
vim = {
3142
treesitter.grammars = with pkgs.vimPlugins.nvim-treesitter.builtGrammars; [
@@ -50,6 +61,10 @@ in {
5061
package = sqlit;
5162
setupModule = "sqlit";
5263
};
64+
"gitlineage.nvim" = mkDashDefault {
65+
package = gitlineage;
66+
setupModule = "gitlineage";
67+
};
5368
"instant.nvim" = mkDashDefault {
5469
package = instant-nvim;
5570
};

config/keybinds.nix

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -488,6 +488,12 @@
488488
action = ''<CMD>AdoPure<CR>'';
489489
desc = "Azure interaction";
490490
}
491+
{
492+
mode = "n";
493+
key = "<leader>gl";
494+
action = ''<CMD>SetupLineage<CR>'';
495+
desc = "Git line history";
496+
}
491497

492498
# ng.nvim
493499
{

config/lua/gitlineage.lua

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
function SetupLineage()
2+
local lineage = require("gitlineage")
3+
lineage.setup({
4+
split = "auto",
5+
keymap = nil,
6+
keys = {
7+
close = "q",
8+
next_commit = "<leader>cn",
9+
prev_commit = "<leader>cp",
10+
yank_commit = "<leader>cy",
11+
open_diff = "<CR>",
12+
},
13+
})
14+
lineage.show_history()
15+
end
16+
17+
vim.api.nvim_create_user_command("SetupLineage", SetupLineage, {})

0 commit comments

Comments
 (0)