Compare commits

...

3 commits

4 changed files with 68 additions and 2 deletions

View file

@ -59,6 +59,27 @@
vimwikiPath = "~/vimwiki";
};
};
"ubuntu" = home-manager.lib.homeManagerConfiguration {
inherit pkgs;
modules = [
./shell
./git
./gpg
./neovim
./horsch.nix
];
extraSpecialArgs = {
user = "ubuntu";
userName = "Michael Mandl";
userEmail = "michael.mandl@horsch.com";
gpgSigningKey = "088ED38F036C7AF2";
gpgSSHKeys = [ "AEB2BF3FF9CF9529E9A3C6F1A202D21686FF9278" ];
theme = "dark";
vimwikiPath = "~/vimwiki";
};
};
};
};
}

View file

@ -85,12 +85,19 @@
lsp_lines-nvim
lsp-inlayhints-nvim
# Copilot
copilot-lua
copilot-cmp
# debugging
nvim-dap
nvim-dap-ui
# vim-wiki
vimwiki
# firenvim
firenvim
];
withNodeJs = true;
@ -137,8 +144,12 @@
require("local_toggleterm")
require("local_notify")
require("local_comment")
if vim.g.started_by_firenvim ~= true then
require("local_lualine")
require("local_tabline")
end
require("local_indent-blankline")
require("local_gitsigns")
require("local_luasnip")
@ -158,6 +169,8 @@
require("nvim-autopairs").setup({})
require("neogen").setup({ snippet_engine = "luasnip" })
require("local_firenvim")
'';
};
};
@ -186,4 +199,5 @@
home.file.".config/nvim/lua/local_dap.lua".source = ./dap.lua;
home.file.".config/nvim/lua/local_illuminate.lua".source = ./illuminate.lua;
home.file.".config/nvim/lua/local_wilder.lua".source = ./wilder.lua;
home.file.".config/nvim/lua/local_firenvim.lua".source = ./firenvim.lua;
}

25
neovim/firenvim.lua Normal file
View file

@ -0,0 +1,25 @@
if vim.g.started_by_firenvim ~= true then
return
end
vim.api.nvim_create_autocmd('UIEnter', {
callback = function()
local client = vim.api.nvim_get_chan_info(vim.v.event.chan).client
if client ~= nil and client.name == "Firenvim" then
vim.o.laststatus = 0
end
end
})
vim.api.nvim_create_autocmd({ 'TextChanged', 'TextChangedI' }, {
callback = function()
if vim.g.timer_started == true then
return
end
vim.g.timer_started = true
vim.fn.timer_start(500, function()
vim.g.timer_started = false
vim.cmd('silent write')
end)
end
})

View file

@ -7,6 +7,11 @@ end
local cmp = require("cmp")
local luasnip = require("luasnip")
local copilot_lua = require("copilot")
local copilot_cmp = require("copilot_cmp")
copilot_lua.setup({})
copilot_cmp.setup({})
cmp.setup({
snippet = {
@ -15,6 +20,7 @@ cmp.setup({
end
},
sources = cmp.config.sources({
{ name = "copilot" },
{ name = "nvim_lsp" },
{ name = "nvim_lsp_signature_help" },
{ name = "luasnip" },