mirror of
https://github.com/kittywitch/nixfiles.git
synced 2026-02-09 12:29:19 -08:00
feat: redo firefox... o:
This commit is contained in:
parent
34bc9ae04e
commit
f113304824
8 changed files with 146 additions and 37 deletions
|
|
@ -19,7 +19,6 @@
|
|||
(set.filter (var: _: string.hasInfix "base" var) config.base16.defaultScheme));
|
||||
in {
|
||||
home.sessionVariables = mkIf config.programs.neovim.enable {EDITOR = "nvim";};
|
||||
|
||||
programs.neovim = {
|
||||
enable = true;
|
||||
vimAlias = true;
|
||||
|
|
@ -57,6 +56,7 @@ in {
|
|||
bufferline-nvim
|
||||
# Language Server
|
||||
nvim-lspconfig
|
||||
rustaceanvim
|
||||
# tree
|
||||
nui-nvim
|
||||
neo-tree-nvim
|
||||
|
|
@ -95,5 +95,8 @@ in {
|
|||
clangStdenv.cc
|
||||
];
|
||||
};
|
||||
xdg.configFile."nvim/init.lua".source = initLua;
|
||||
xdg.configFile = {
|
||||
"nvim/init.lua".source = initLua;
|
||||
"nvim/after/ftplugin/rust.lua".source = ./rust.lua;
|
||||
};
|
||||
}
|
||||
|
|
|
|||
18
home/profiles/neovim/rust.lua
Normal file
18
home/profiles/neovim/rust.lua
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
local bufnr = vim.api.nvim_get_current_buf()
|
||||
vim.keymap.set(
|
||||
"n",
|
||||
"<leader>a",
|
||||
function()
|
||||
vim.cmd.RustLsp('codeAction') -- supports rust-analyzer's grouping
|
||||
-- or vim.lsp.buf.codeAction() if you don't want grouping.
|
||||
end,
|
||||
{ silent = true, buffer = bufnr }
|
||||
)
|
||||
vim.keymap.set(
|
||||
"n",
|
||||
"K", -- Override Neovim's built-in hover keymap with rustaceanvim's hover actions
|
||||
function()
|
||||
vim.cmd.RustLsp({'hover', 'actions'})
|
||||
end,
|
||||
{ silent = true, buffer = bufnr }
|
||||
)
|
||||
Loading…
Add table
Add a link
Reference in a new issue