nixvim: add lazygit and diffview plugins with keymaps

Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
This commit is contained in:
2026-03-11 17:22:24 +09:00
co-authored by Claude Sonnet 4.6
parent bec1f3cedf
commit e0ee31d321
3 changed files with 17 additions and 0 deletions
+6
View File
@@ -52,6 +52,12 @@ in {
(mk "]b" "<Cmd>BufferNext<CR>" "後のバッファーに移動") (mk "]b" "<Cmd>BufferNext<CR>" "後のバッファーに移動")
(mk "<leader>bc" "<Cmd>BufferClose<CR>" "バッファーを削除") (mk "<leader>bc" "<Cmd>BufferClose<CR>" "バッファーを削除")
# Git
(mk "<leader>gl" "<cmd>LazyGit<CR>" "LazyGitを開く")
(mk "<leader>gd" "<cmd>DiffviewOpen<CR>" "差分を開く")
(mk "<leader>gH" "<cmd>DiffviewFileHistory<CR>" "リポジトリ履歴")
(mk "<leader>gh" "<cmd>DiffviewFileHistory %<CR>" "ファイル履歴")
# Telescope (explicit form for reliability) # Telescope (explicit form for reliability)
(mkRaw "<leader>ff" "function() require('telescope.builtin').find_files() end" "ファイルを探す") (mkRaw "<leader>ff" "function() require('telescope.builtin').find_files() end" "ファイルを探す")
(mkRaw "<leader>fg" "function() require('telescope.builtin').live_grep() end" "文字列を全文検索") (mkRaw "<leader>fg" "function() require('telescope.builtin').live_grep() end" "文字列を全文検索")
@@ -11,5 +11,6 @@
./trouble.nix ./trouble.nix
./conform.nix ./conform.nix
./surround.nix ./surround.nix
./git.nix
]; ];
} }
@@ -0,0 +1,10 @@
{ pkgs, ... }: {
programs.nixvim = {
extraPackages = [ pkgs.lazygit ];
plugins = {
lazygit.enable = true;
diffview.enable = true;
};
};
}