This commit is contained in:
Hadi 2024-10-08 20:02:45 +02:00
parent a781a227ac
commit 3f0a694b5f
8 changed files with 74 additions and 36 deletions

View File

@ -10,7 +10,6 @@ feel free to contribute <3 ([CONTRIBUTING.md](CONTRIBUTING.md))
- [ ] OS Hardening with nix-mineral
- [ ] Nixvim
- [ ] Telescope Theme
- [ ] Markdown tab size 2
- [ ] UFO for folding
- [ ] neotest golang

View File

@ -8,6 +8,8 @@
./plugins/tree.nix
./plugins/ui.nix
./plugins/utils.nix
./plugins/dap.nix
./plugins/telescope.nix
./options.nix
./keymaps.nix

View File

@ -243,7 +243,7 @@
options.desc = "Close";
}
# code
# Code
{
key = "<leader>cd";
action = "<cmd>lua vim.lsp.buf.definition()<cr>";
@ -254,26 +254,11 @@
action = "<cmd>lua vim.lsp.buf.references()<cr>";
options.desc = "LSP References";
}
{
key = "<leader>ci";
action = "<cmd>lua vim.lsp.buf.implementation()<cr>";
options.desc = "LSP Implementation";
}
{
key = "<leader>ct";
action = "<cmd>lua vim.lsp.buf.type_definition()<cr>";
options.desc = "LSP Type Definition";
}
{
key = "<leader>cs";
action = "<cmd>lua vim.lsp.buf.signature_help()<cr>";
options.desc = "LSP Signature Help";
}
{
key = "<leader>ch";
action = "<cmd>lua vim.lsp.buf.hover()<cr>";
options.desc = "LSP Hover";
}
{
key = "<leader>ca";
action = "<cmd>lua vim.lsp.buf.code_action()<cr>";
@ -284,11 +269,6 @@
action = "<cmd>lua vim.lsp.buf.formatting()<cr>";
options.desc = "LSP Formatting";
}
{
key = "<leader>ce";
action = "<cmd>lua vim.lsp.diagnostic.show_line_diagnostics()<cr>";
options.desc = "LSP Line Diagnostics";
}
{
key = "<leader>cn";
action = "<cmd>lua vim.lsp.diagnostic.goto_next()<cr>";
@ -299,7 +279,16 @@
action = "<cmd>lua vim.lsp.diagnostic.goto_prev()<cr>";
options.desc = "LSP Previous Diagnostic";
}
{
key = "<leader>cu";
action = "<cmd>lua require('dapui').toggle()<CR>";
options.desc = "Toggle Dapui";
}
{
key = "<leader>cb";
action = "<cmd>lua require('dap').toggle_breakpoint()<CR>";
options.desc = "Toggle breakpoint";
}
];
};
}

View File

@ -0,0 +1,28 @@
{ pkgs, ... }: {
programs.nixvim.plugins.dap = {
enable = true;
adapters = { };
signs = {
dapBreakpoint = {
text = "";
texthl = "DapBreakpoint";
};
dapBreakpointCondition = {
text = "";
texthl = "DapBreakpointCondition";
};
dapLogPoint = {
text = "";
texthl = "DapLogPoint";
};
};
extensions = {
dap-go = {
enable = true;
delve.path = "${pkgs.delve}/bin/dlv";
};
dap-ui = { enable = true; };
dap-virtual-text = { enable = true; };
};
};
}

View File

@ -0,0 +1,26 @@
{ config, ... }: {
programs.nixvim = {
highlight = {
TelescopePromptPrefix.fg = "#${config.lib.stylix.colors.base0D}";
TelescopeSelectionCaret = {
fg = "#${config.lib.stylix.colors.base0D}";
bg = "#${config.lib.stylix.colors.base01}";
};
TelescopeSelection.bg = "#${config.lib.stylix.colors.base01}";
TelescopePromptTitle = {
bg = "#${config.lib.stylix.colors.base00}";
fg = "#${config.lib.stylix.colors.base0D}";
};
TelescopePromptNormal.bg = "#${config.lib.stylix.colors.base00}";
TelescopePromptBorder = {
bg = "#${config.lib.stylix.colors.base00}";
fg = "#${config.lib.stylix.colors.base0D}";
};
};
plugins.telescope = {
enable = true;
extensions.fzf-native = { enable = true; };
settings.defaults = { selection_caret = " "; };
};
};
}

View File

@ -6,6 +6,8 @@
lualine = {
enable = true;
settings = {
options.disabled_filetypes.statusline =
[ "dashboard" "alpha" "neo-tree" ];
alwaysDivideMiddle = true;
globalstatus = true;
@ -30,10 +32,12 @@
};
};
};
dap.enable = true;
web-devicons.enable = true;
noice.enable = true;
notify.enable = true;
notify = {
enable = true;
level = "warn";
};
gitsigns = {
enable = true;
settings.current_line_blame = false;

View File

@ -17,14 +17,6 @@
comment.enable = true;
nvim-autopairs.enable = true;
friendly-snippets.enable = true;
telescope = {
enable = true;
extensions.fzf-native = { enable = true; };
settings = {
selection_caret = "/ ";
layout_config = { prompt_position = "top"; };
};
};
todo-comments.enable = true;
treesitter = {
enable = true;
@ -34,7 +26,6 @@
highlight.enable = true;
};
};
# TODO: Add not working
harpoon = {
enable = true;
enableTelescope = true;

View File

@ -44,7 +44,6 @@
xfce.thunar
bitwarden
vlc
figma-linux
# Dev
go
@ -60,13 +59,13 @@
pfetch
pandoc
btop
cava
# Just cool
peaclock
cbonsai
pipes
cmatrix
cava
# Backup
vscode