Compare commits

..

No commits in common. "cacb3603a6a3c0a2817e5417171d7729f5d039fa" and "ec6dbf60e8bc6e1b2d4565a1c62f892697f05712" have entirely different histories.

6 changed files with 22 additions and 202 deletions

View file

@ -35,4 +35,4 @@ nix run git+https://git.sajenim.dev/jasmine/nvim.nix.git
## References
* [dc-tec/nixvim](https://github.com/dc-tec/nixvim)
* [elythh/nixvim](https://github.com/elythh/nixvim)

View file

@ -4,107 +4,5 @@
plugins.gitsigns = {
enable = true;
};
keymaps = [
{
mode = [ "n" "v" ];
key = "<leader>hs";
action = "<cmd>Gitsigns stage_hunk<cr>";
options = {
silent = true;
desc = "Stage Hunk";
};
}
{
mode = [ "n" "v" ];
key = "<leader>hr";
action = "<cmd>Gitsigns reset_hunk<cr>";
options = {
silent = true;
desc = "Reset Hunk";
};
}
{
mode = "n";
key = "<leader>hS";
action = "<cmd>Gitsigns stage_buffer<cr>";
options = {
silent = true;
desc = "Stage Buffer";
};
}
{
mode = "n";
key = "<leader>hu";
action = "<cmd>Gitsigns undo_stage_hunk<cr>";
options = {
silent = true;
desc = "Undo Staged Hunk";
};
}
{
mode = "n";
key = "<leader>hR";
action = "<cmd>Gitsigns reset_buffer<cr>";
options = {
silent = true;
desc = "Reset Buffer";
};
}
{
mode = "n";
key = "<leader>hp";
action = "<cmd>Gitsigns preview_hunk_inline<cr>";
options = {
silent = true;
desc = "Preview Hunk";
};
}
{
mode = "n";
key = "<leader>hb";
action = "<cmd>Gitsigns blame<cr>";
options = {
silent = true;
desc = "View Blame";
};
}
{
mode = "n";
key = "<leader>tb";
action = "<cmd>Gitsigns toggle_current_line_blame<cr>";
options = {
silent = true;
desc = "Toggle Blame";
};
}
{
mode = "n";
key = "<leader>hd";
action = "<cmd>Gitsigns diffthis<cr>";
options = {
silent = true;
desc = "View Diff";
};
}
{
mode = "n";
key = "<leader>td";
action = "<cmd>Gitsigns toggle_deleted<cr>";
options = {
silent = true;
desc = "Toggle Deleted";
};
}
];
}

View file

@ -16,11 +16,7 @@
sectionSeparators = { left = ""; right = ""; };
# Display components in tabline
tabline = {
lualine_a = [ { name = "buffers"; } ];
lualine_x = [ { name = "hostname"; } ];
lualine_z = [ { name = "encoding"; } ];
};
tabline.lualine_a = [ { name = "buffers"; } ];
# Lualine has sections as shown below
# +-------------------------------------------------+
@ -28,7 +24,7 @@
# +-------------------------------------------------+
sections = {
# Section A
lualine_a = [ { name = "mode"; } ];
lualine_a = [ { name = "mode"; icon = ""; } ];
# Section B
lualine_b = [
@ -38,32 +34,36 @@
# Git diff status
{ name = "diff";
extraConfig.symbols = {
added = "+";
modified = "~";
removed = "-";
added = " ";
modified = " ";
removed = " ";
};
}
];
# Section C
lualine_c = [ { name = "filename"; } ];
# Section X
lualine_x = [
# Diagnostic count from nvim_lsp
{ name = "diagnostics";
extraConfig = {
sources = [ "nvim_lsp" ];
symbols = {
error = "error:";
warn = "warning:";
info = "info:";
hint = "hint:";
error = " ";
warn = " ";
info = " ";
hint = "󰝶 ";
};
};
}
];
# Section C
lualine_c = [ { name = "filename"; extraConfig = { path = 1; }; } ];
# Section X
lualine_x = [
{ name = "encoding"; }
{ name = "fileformat"; }
{ name = "filetype"; }
];
# Section Y
lualine_y = [ { name = "progress"; } ];

View file

@ -1,18 +0,0 @@
{ pkgs, ... }:
{
extraPlugins = [(pkgs.vimUtils.buildVimPlugin {
name = "neoclip";
src = pkgs.fetchFromGitHub {
owner = "AckslD";
repo = "nvim-neoclip.lua";
rev = "709c97f";
hash = "sha256-8ZPmxVM4dzjJxAYUHRMCiAQBxZEGHtsgSCNlCZBRBWo=";
};
})];
extraConfigLua = "require('neoclip').setup({
default_register = {'\"', '+'}
})";
}

View file

@ -1,14 +0,0 @@
{ pkgs, ... }:
{
extraPlugins = [(pkgs.vimUtils.buildVimPlugin {
name = "software-licenses";
src = pkgs.fetchFromGitHub {
owner = "chip";
repo = "telescope-software-licenses.nvim";
rev = "fb5fc33";
hash = "sha256-luyCjkZSm1F6qoRpP5hHRAx4632u6JFuX2s7m2s8y60=";
};
})];
}

View file

@ -1,63 +1,17 @@
{ ... }:
{
imports = [
./neoclip.nix # Persistent clipboard.
./software-licenses.nix # View common software licenses.
];
plugins.telescope = {
enable = true;
# Install some telescope extensions.
extensions = {
# Enable native fuzzy finder.
fzf-native = {
enable = true;
};
};
# Configure our telescope keymaps.
keymaps = {
"<leader>ff" = {
action = "find_files";
options = {
desc = "Find project files";
};
options.desc = "Find Files";
};
"<leader>fb" = {
action = "buffers";
options = {
desc = "Find open buffers";
};
};
"<leader>/" = {
action = "live_grep";
options = {
desc = "Grep (root dir)";
};
};
"<leader>:" = {
action = "command_history";
options = {
desc = "Command History";
};
};
"<leader>p" = {
action = "neoclip";
options.desc = "Persistent Clipboard";
};
"<leader>sc" = {
action = "commands";
options = {
desc = "Search Commands";
};
};
"<leader>sl" = {
action = "software-licenses find";
options = {
desc = "Search Software Licenses";
};
options.desc = "Buffers";
};
};
};