Compare commits
2
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
4473056bf3 | ||
|
|
f5a6072bb5 |
No files matched your search
@@ -0,0 +1,21 @@
|
|||||||
|
{
|
||||||
|
programs.nixvim = {
|
||||||
|
plugins = {
|
||||||
|
blink-indent.enable = true;
|
||||||
|
blink-pairs.enable = true;
|
||||||
|
blink-cmp = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
signature.enabled = true;
|
||||||
|
keymap = {
|
||||||
|
preset = "default";
|
||||||
|
"<CR>" = [
|
||||||
|
"accept"
|
||||||
|
"fallback"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -1,66 +0,0 @@
|
|||||||
{
|
|
||||||
programs.nixvim = {
|
|
||||||
opts.completeopt = [
|
|
||||||
"menu"
|
|
||||||
"menuone"
|
|
||||||
"noselect"
|
|
||||||
];
|
|
||||||
|
|
||||||
plugins = {
|
|
||||||
lspkind.enable = true;
|
|
||||||
|
|
||||||
cmp = {
|
|
||||||
enable = true;
|
|
||||||
|
|
||||||
autoEnableSources = true;
|
|
||||||
|
|
||||||
settings = {
|
|
||||||
snippet.expand = "function(args) vim.snippet.expand(args.body) end";
|
|
||||||
|
|
||||||
formatting.fields = [
|
|
||||||
"abbr"
|
|
||||||
"icon"
|
|
||||||
"menu"
|
|
||||||
];
|
|
||||||
|
|
||||||
mapping = {
|
|
||||||
"<C-p>" = "cmp.mapping.select_prev_item()";
|
|
||||||
"<C-n>" = "cmp.mapping.select_next_item()";
|
|
||||||
"<C-b>" = "cmp.mapping.scroll_docs(-4)";
|
|
||||||
"<C-f>" = "cmp.mapping.scroll_docs(4)";
|
|
||||||
"<C-e>" = "cmp.mapping.close()";
|
|
||||||
"<C-y>" = "cmp.mapping.confirm({ select = true })";
|
|
||||||
"<CR>" = "cmp.mapping.confirm({ select = true })";
|
|
||||||
"<C-Space>" = "cmp.mapping.complete()";
|
|
||||||
"<C-l>" = ''
|
|
||||||
cmp.mapping(
|
|
||||||
function()
|
|
||||||
if vim.snippet.active({ direction = 1 }) then
|
|
||||||
vim.snippet.jump(1)
|
|
||||||
end
|
|
||||||
end,
|
|
||||||
{'i', 's'}
|
|
||||||
)
|
|
||||||
'';
|
|
||||||
"<C-h>" = ''
|
|
||||||
cmp.mapping(
|
|
||||||
function()
|
|
||||||
if vim.snippet.active({ direction = -1 }) then
|
|
||||||
vim.snippet.jump(-1)
|
|
||||||
end
|
|
||||||
end,
|
|
||||||
{'i', 's'}
|
|
||||||
)
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
sources = [
|
|
||||||
{ name = "nvim_lsp"; }
|
|
||||||
{ name = "nvim_lsp_signature_help"; }
|
|
||||||
{ name = "path"; }
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,24 +1,17 @@
|
|||||||
{ pkgs, ... }:
|
{ pkgs, ... }:
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./cmp.nix
|
./blink.nix
|
||||||
./dap.nix
|
./dap.nix
|
||||||
./lsp.nix
|
./lsp.nix
|
||||||
./fmt.nix
|
./fmt.nix
|
||||||
./treesitter.nix
|
./treesitter.nix
|
||||||
./telescope.nix
|
./telescope.nix
|
||||||
./lualine.nix
|
./lualine.nix
|
||||||
./nvim-autopairs.nix
|
|
||||||
./which-key.nix
|
./which-key.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
programs.nixvim = {
|
programs.nixvim = {
|
||||||
plugins = {
|
|
||||||
lz-n.enable = true;
|
|
||||||
indent-blankline.enable = true;
|
|
||||||
web-devicons.enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
extraPlugins = with pkgs.vimPlugins; [
|
extraPlugins = with pkgs.vimPlugins; [
|
||||||
vim-sleuth
|
vim-sleuth
|
||||||
];
|
];
|
||||||
|
|||||||
@@ -3,22 +3,18 @@
|
|||||||
programs.nixvim = {
|
programs.nixvim = {
|
||||||
opts.formatexpr = "v:lua.require'conform'.formatexpr()";
|
opts.formatexpr = "v:lua.require'conform'.formatexpr()";
|
||||||
|
|
||||||
plugins.conform-nvim = {
|
keymaps = [
|
||||||
enable = true;
|
|
||||||
lazyLoad.enable = true;
|
|
||||||
lazyLoad.settings = {
|
|
||||||
event = "BufWritePre";
|
|
||||||
cmd = "ConformInfo";
|
|
||||||
keys = [
|
|
||||||
{
|
{
|
||||||
__unkeyed-1 = "<leader>f";
|
key = "<leader>f";
|
||||||
__unkeyed-2.__raw = ''
|
action.__raw = ''
|
||||||
function() require 'conform'.format { async = true } end
|
function() require 'conform'.format { async = true } end
|
||||||
'';
|
'';
|
||||||
desc = "Format Buffer";
|
options.desc = "Format Buffer";
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
};
|
|
||||||
|
plugins.conform-nvim = {
|
||||||
|
enable = true;
|
||||||
settings = {
|
settings = {
|
||||||
default_format_opts.lsp_format = "fallback";
|
default_format_opts.lsp_format = "fallback";
|
||||||
format_on_save = {
|
format_on_save = {
|
||||||
|
|||||||
@@ -1,9 +0,0 @@
|
|||||||
{
|
|
||||||
programs.nixvim.plugins.nvim-autopairs = {
|
|
||||||
enable = true;
|
|
||||||
lazyLoad = {
|
|
||||||
enable = true;
|
|
||||||
settings.event = "InsertEnter";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,9 +1,3 @@
|
|||||||
{
|
{
|
||||||
programs.nixvim.plugins.which-key = {
|
programs.nixvim.plugins.which-key.enable = true;
|
||||||
enable = true;
|
|
||||||
lazyLoad = {
|
|
||||||
enable = true;
|
|
||||||
settings.event = "VimEnter";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
Reference in new issue
Block a user