Added activity watch

- added code companion
- added neogen for annotations
- remapped trouble keybinds
- some other stuff idk
This commit is contained in:
Barna Máté 2024-12-15 09:31:17 +01:00
parent 13fda9ebf6
commit 09ebce4613
8 changed files with 76 additions and 30 deletions

View file

@ -0,0 +1,49 @@
{ pkgs, ... }: {
plugins.codecompanion = {
enable = true;
settings = {
adapters = {
ollama = {
__raw = ''
function()
return require('codecompanion.adapters').extend('ollama', {
env = {
url = "http://127.0.0.1:11434",
},
schema = {
model = {
default = 'qwen2.5-coder:latest',
-- default = "llama3.1:8b-instruct-q8_0",
},
num_ctx = {
default = 32768,
},
},
})
end
'';
};
};
opts = {
log_level = "TRACE";
send_code = true;
use_default_actions = true;
use_default_prompts = true;
};
strategies = {
agent = {
adapter = "ollama";
};
chat = {
adapter = "ollama";
};
inline = {
adapter = "ollama";
};
};
};
};
}

View file

@ -1,5 +1,5 @@
{ pkgs, ... }: { { pkgs, ... }: {
# Activity watch for vim to keep track of time in files. Fuck wakatime
extraPlugins = with pkgs; [ extraPlugins = with pkgs; [
{ {
plugin = pkgs.vimUtils.buildVimPlugin { plugin = pkgs.vimUtils.buildVimPlugin {

View file

@ -1,12 +1,16 @@
{ pkgs, ... }: { { pkgs, ... }: {
imports = [ imports = [
./ai
./aw
./lang
./lsp ./lsp
./telescope ./telescope
./ui ./ui
./aw
./lang
]; ];
# Persistence # Persistence
plugins.persistence.enable = true; plugins.persistence.enable = true;
} }

View file

@ -1,5 +1,6 @@
{ pkgs, ... }: { { pkgs, ... }: {
# Formatters and language servers for programming languages
imports = [ imports = [
./css.nix ./css.nix
./docker.nix ./docker.nix
@ -13,4 +14,5 @@
# TODO elixir # TODO elixir
# TODO java # TODO java
]; ];
} }

View file

@ -2,6 +2,7 @@
imports = [ imports = [
./trouble.nix ./trouble.nix
./neogen.nix
]; ];
# Autocomplete # Autocomplete

View file

@ -0,0 +1,8 @@
{ pkgs, ... }: {
plugins.neogen = {
enable = true;
keymaps.generated = "<leader>ag";
};
}

View file

@ -5,46 +5,24 @@
}; };
keymaps = [ keymaps = [
{
mode = "n";
key = "<leader>x";
action = "+diagnostics/quickfix";
}
{ {
mode = "n"; mode = "n";
key = "<leader>xx"; key = "<leader>xx";
action = "<cmd>TroubleToggle<cr>"; action = "<cmd>Trouble diagnostics<cr>";
options = { options = {
silent = true; silent = true;
desc = "Document Diagnostics (Trouble)"; desc = "Show trouble diagnostics";
};
}
{
mode = "n";
key = "<leader>xX";
action = "<cmd>TroubleToggle workspace_diagnostics<cr>";
options = {
silent = true;
desc = "Workspace Diagnostics (Trouble)";
}; };
} }
{ {
mode = "n"; mode = "n";
key = "<leader>xt"; key = "<leader>xt";
action = "<cmd>TroubleToggle todo<cr>"; action = "<cmd>Trouble TODO's<cr>";
options = { options = {
silent = true; silent = true;
desc = "Todo (Trouble)"; desc = "Show TODOs";
};
}
{
mode = "n";
key = "<leader>xq";
action = "<cmd>TodoQuickFix<cr>";
options = {
silent = true;
desc = "Quickfix List (Trouble)";
}; };
} }
]; ];
} }

View file

@ -159,6 +159,10 @@
# Status bar # Status bar
plugins.lualine = { plugins.lualine = {
enable = true; enable = true;
settings.sections = {
# TODO display absolute path based on project. for example on this file neo2005/config/plugins/ui/default.nix
# lualine_c = ["{ {'filename', path = 1}, },"];
};
}; };
# Startup dashboard # Startup dashboard
plugins.alpha = { plugins.alpha = {