cleanup nixvim files, add cmake and asm lsp
This commit is contained in:
parent
17cb055b71
commit
dabf5d006a
|
|
@ -1,7 +1,6 @@
|
|||
{
|
||||
imports = [
|
||||
./yank_highlight.nix
|
||||
#./remember_cursor_position.nix
|
||||
./set_conceal_level.nix
|
||||
./filetype_options.nix
|
||||
];
|
||||
|
|
|
|||
|
|
@ -1,35 +0,0 @@
|
|||
let
|
||||
group = "RememberCursorPosition";
|
||||
in {
|
||||
autoGroups = {
|
||||
${group} = {
|
||||
clear = true;
|
||||
};
|
||||
};
|
||||
autoCmd = [
|
||||
{
|
||||
inherit group;
|
||||
event = "BufRead";
|
||||
callback = {
|
||||
__raw = ''
|
||||
function(opts)
|
||||
buffer = opts.buf,
|
||||
vim.api.nvim_create_autocmd("BufWinEnter", {
|
||||
callback = function()
|
||||
local ft = vim.bo[opts.buf].filetype
|
||||
local last_known_line = vim.api.nvim_buf_get_mark(opts.buf, '"')[1]
|
||||
if
|
||||
not (ft:match("commit") and ft:match("rebase"))
|
||||
and last_known_line > 1
|
||||
and last_known_line <= vim.api.nvim_buf_line_count(opts.buf)
|
||||
then
|
||||
vim.api.nvim_feedkeys([[g`"]], "nx", false)
|
||||
end
|
||||
end,
|
||||
})
|
||||
end
|
||||
'';
|
||||
};
|
||||
}
|
||||
];
|
||||
}
|
||||
|
|
@ -78,6 +78,7 @@ in {
|
|||
alejandra
|
||||
vscode-extensions.ms-vscode.cpptools
|
||||
nixpkgs-fmt
|
||||
asm-lsp
|
||||
];
|
||||
extraPlugins = with pkgs.vimPlugins; [
|
||||
{
|
||||
|
|
@ -188,6 +189,9 @@ in {
|
|||
dap.listeners.before.event_exited.dapui_config = function()
|
||||
dapui.close()
|
||||
end
|
||||
|
||||
|
||||
require('lspconfig').asm_lsp.setup({})
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
store_selection_keys = "<Tab>";
|
||||
};
|
||||
fromLua = [
|
||||
{ paths = ../../snippets; }
|
||||
{ paths = ../snippets; }
|
||||
];
|
||||
};
|
||||
lspkind = {
|
||||
|
|
@ -6,7 +6,5 @@
|
|||
cfg = config.programs.nixvim.ai;
|
||||
in
|
||||
lib.mkIf cfg.enable {
|
||||
plugins.codeium-nvim = {
|
||||
enable = true;
|
||||
};
|
||||
plugins.codeium-nvim.enable = true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,29 +1,34 @@
|
|||
{pkgs, ...}: {
|
||||
imports = [
|
||||
./gitsigns.nix
|
||||
./cmp.nix
|
||||
./codeium.nix
|
||||
./dap.nix
|
||||
./harpoon.nix
|
||||
./indent-blankline.nix
|
||||
./lsp
|
||||
./lualine.nix
|
||||
./mini.nix
|
||||
./neo-tree.nix
|
||||
./neorg.nix
|
||||
./noice.nix
|
||||
./none-ls.nix
|
||||
./rainbow-delimiters.nix
|
||||
./telescope.nix
|
||||
./treesitter.nix
|
||||
./trouble.nix
|
||||
./vim-tmux-navigator.nix
|
||||
./which-key.nix
|
||||
./mini.nix
|
||||
./todo-comments.nix
|
||||
./neorg.nix
|
||||
./fugitive.nix
|
||||
./dap.nix
|
||||
./lastplace.nix
|
||||
./codeium.nix
|
||||
./undotree.nix
|
||||
./transparent.nix
|
||||
./lsp
|
||||
];
|
||||
|
||||
plugins = {
|
||||
fugitive.enable = true;
|
||||
gitsigns.enable = true;
|
||||
lastplace.enable = true;
|
||||
tmux-navigator.enable = true;
|
||||
todo-comments.enable = true;
|
||||
transparent.enable = true;
|
||||
which-key.enable = true;
|
||||
};
|
||||
|
||||
extraPlugins = with pkgs.vimPlugins;
|
||||
[
|
||||
vim-nftables
|
||||
|
|
|
|||
|
|
@ -1,3 +0,0 @@
|
|||
{
|
||||
plugins.fugitive.enable = true;
|
||||
}
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
{
|
||||
plugins.gitsigns.enable = true;
|
||||
}
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
{
|
||||
plugins.lastplace.enable = true;
|
||||
}
|
||||
|
|
@ -1,7 +1,6 @@
|
|||
{
|
||||
imports = [
|
||||
./languages
|
||||
./cmp.nix
|
||||
./lsp.nix
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +0,0 @@
|
|||
{
|
||||
plugins.lsp.servers.clangd = {
|
||||
enable = true;
|
||||
};
|
||||
}
|
||||
|
|
@ -1,21 +1,26 @@
|
|||
{
|
||||
imports = [
|
||||
./rust.nix
|
||||
./lua.nix
|
||||
./nix.nix
|
||||
./go.nix
|
||||
./htmx.nix
|
||||
./typescript.nix
|
||||
./emmet.nix
|
||||
./eslint.nix
|
||||
./go.nix
|
||||
./html.nix
|
||||
./json.nix
|
||||
./python.nix
|
||||
./tailwindcss.nix
|
||||
./yaml.nix
|
||||
./c.nix
|
||||
./templ.nix
|
||||
./sql.nix
|
||||
./php.nix
|
||||
./nix.nix
|
||||
./rust.nix
|
||||
];
|
||||
|
||||
plugins.lsp.servers = {
|
||||
clangd.enable = true;
|
||||
cmake.enable = true;
|
||||
eslint.enable = true;
|
||||
htmx.enable = true;
|
||||
jsonls.enable = true;
|
||||
lua-ls.enable = true;
|
||||
phpactor.enable = true;
|
||||
ruff-lsp.enable = true;
|
||||
pyright.enable = true;
|
||||
sqls.enable = true;
|
||||
tailwindcss.enable = true;
|
||||
templ.enable = true;
|
||||
tsserver.enable = true;
|
||||
yamlls.enable = true;
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,9 +0,0 @@
|
|||
{
|
||||
plugins.lsp = {
|
||||
servers = {
|
||||
eslint = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
{
|
||||
plugins.lsp = {
|
||||
servers = {
|
||||
htmx.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
{
|
||||
plugins.lsp = {
|
||||
servers = {
|
||||
jsonls.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
{
|
||||
plugins.lsp = {
|
||||
servers = {
|
||||
lua-ls.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
{
|
||||
plugins.lsp = {
|
||||
servers = {
|
||||
#phpactor.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -1,8 +0,0 @@
|
|||
{
|
||||
plugins.lsp = {
|
||||
servers = {
|
||||
ruff-lsp.enable = true;
|
||||
pyright.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -1,5 +0,0 @@
|
|||
{
|
||||
plugins.lsp.servers.sqls = {
|
||||
enable = true;
|
||||
};
|
||||
}
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
{
|
||||
plugins.lsp = {
|
||||
servers = {
|
||||
tailwindcss.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
{
|
||||
plugins.lsp = {
|
||||
servers = {
|
||||
templ.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
{
|
||||
plugins.lsp = {
|
||||
servers = {
|
||||
tsserver.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -1,5 +0,0 @@
|
|||
{
|
||||
plugins.lsp.servers = {
|
||||
yamlls.enable = true;
|
||||
};
|
||||
}
|
||||
|
|
@ -13,6 +13,7 @@
|
|||
formatting = {
|
||||
phpcbf.enable = true;
|
||||
goimports.enable = true;
|
||||
asmfmt.enable = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
|||
|
|
@ -1,3 +0,0 @@
|
|||
{
|
||||
plugins.todo-comments.enable = true;
|
||||
}
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
{
|
||||
plugins.tmux-navigator.enable = true;
|
||||
}
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
{
|
||||
plugins.which-key.enable = true;
|
||||
}
|
||||
|
|
@ -1,8 +1,7 @@
|
|||
local ls = require("luasnip")
|
||||
|
||||
-- for "all" filetypes create snippet for "func"
|
||||
ls.add_snippets( "all", {
|
||||
ls.add_snippets( "go", {
|
||||
ls.parser.parse_snippet(
|
||||
'iferr',
|
||||
'if err != nil {\n\t${1}\n}'),
|
||||
})
|
||||
})
|
||||
|
|
|
|||
Loading…
Reference in New Issue