change git-worktree to polarmutex version
This commit is contained in:
parent
975cd5d27f
commit
8be8c217d3
|
@ -23,6 +23,7 @@ in {
|
|||
./todo-comments.nix
|
||||
./oil.nix
|
||||
./comment.nix
|
||||
./git-workree.nix
|
||||
];
|
||||
|
||||
programs.nixvim.plugins.web-devicons.enable = true;
|
||||
|
|
|
@ -1,11 +1,44 @@
|
|||
{pkgs, ...}:
|
||||
{
|
||||
programs.nixvim.plugins.git-worktree = {
|
||||
enable = true;
|
||||
enableTelescope = true;
|
||||
autopush = true;
|
||||
changeDirectoryCommand = "cd";
|
||||
clearJumpsOnChange = true;
|
||||
updateOnChange = true;
|
||||
updateOnChangeCommand = "e .";
|
||||
programs.nixvim.keymaps = [
|
||||
# Switching worktrees
|
||||
{
|
||||
mode = ["n"];
|
||||
key = "<leader>fws";
|
||||
action = "<cmd>lua require('telescope').extensions.git_worktree.git_worktrees()<CR>";
|
||||
options = {noremap = true;};
|
||||
}
|
||||
{
|
||||
mode = ["n"];
|
||||
key = "<leader>fwc";
|
||||
action = "<cmd>lua require('telescope').extensions.git_worktree.create_git_worktree()<CR>";
|
||||
options = {noremap = true;};
|
||||
}
|
||||
];
|
||||
|
||||
programs.nixvim.extraPlugins = [
|
||||
|
||||
(pkgs.vimUtils.buildVimPlugin
|
||||
{
|
||||
name = "git-worktree.nvim";
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "glow.nvim";
|
||||
repo = "git-worktree.nvim";
|
||||
rev = "bac72c2";
|
||||
sha256 = "";
|
||||
};
|
||||
})
|
||||
];
|
||||
|
||||
programs.nixvim.extraConfigLua = ''
|
||||
'';
|
||||
# programs.nixvim.plugins.git-worktree = {
|
||||
# enable = true;
|
||||
# enableTelescope = true;
|
||||
# autopush = true;
|
||||
# changeDirectoryCommand = "cd";
|
||||
# clearJumpsOnChange = true;
|
||||
# updateOnChange = true;
|
||||
# updateOnChangeCommand = "e .";
|
||||
# };
|
||||
}
|
||||
|
|
|
@ -46,5 +46,12 @@
|
|||
action = "<cmd>Telescope oldfiles<CR>";
|
||||
options = {noremap = true;};
|
||||
}
|
||||
{
|
||||
# show recently opened files
|
||||
mode = ["n"];
|
||||
key = "<Leader>fk";
|
||||
action = "<cmd>Telescope keymaps<CR>";
|
||||
options = {noremap = true;};
|
||||
}
|
||||
];
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue