mirror of
https://github.com/Theaninova/TheaninovOS.git
synced 2025-12-12 11:36:20 +00:00
neovim improvements
This commit is contained in:
@@ -24,6 +24,8 @@
|
|||||||
"ags"
|
"ags"
|
||||||
"swww init"
|
"swww init"
|
||||||
"swww img ~/Pictures/Wallpapers/wallpaper.jpg"
|
"swww img ~/Pictures/Wallpapers/wallpaper.jpg"
|
||||||
|
"systemctl --user import-environment DISPLAY WAYLAND_DISPLAY XAUTHORITY"
|
||||||
|
"dbus-update-activation-environment DISPLAY WAYLAND_DISPLAY XAUTHORITY"
|
||||||
"gnome-keyring-daemon --start --components=secrets"
|
"gnome-keyring-daemon --start --components=secrets"
|
||||||
"${pkgs.polkit_gnome}/libexec/polkit-gnome-authentication-agent-1"
|
"${pkgs.polkit_gnome}/libexec/polkit-gnome-authentication-agent-1"
|
||||||
];
|
];
|
||||||
|
|||||||
2
home.nix
2
home.nix
@@ -27,7 +27,7 @@ in {
|
|||||||
};
|
};
|
||||||
|
|
||||||
programs = import ./programs.nix { inherit pkgs; };
|
programs = import ./programs.nix { inherit pkgs; };
|
||||||
services = import ./services.nix;
|
services = import ./services.nix { inherit pkgs; };
|
||||||
|
|
||||||
home.file.".p10k.zsh".source = ./programs/.p10k.zsh;
|
home.file.".p10k.zsh".source = ./programs/.p10k.zsh;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -56,4 +56,5 @@
|
|||||||
|
|
||||||
# utils
|
# utils
|
||||||
neofetch
|
neofetch
|
||||||
|
pinentry-gnome
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -21,7 +21,7 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
keymaps = [
|
keymaps = [
|
||||||
{ key = "<F9>"; mode = "n"; action = "<cmd>:UndotreeToggle<CR>"; }
|
{ key = "<leader>u"; mode = "n"; action = "<cmd>:UndotreeToggle<CR>"; }
|
||||||
];
|
];
|
||||||
|
|
||||||
globals = {
|
globals = {
|
||||||
@@ -29,7 +29,7 @@
|
|||||||
minimap_auto_start = 1;
|
minimap_auto_start = 1;
|
||||||
minimap_auto_start_win_enter = 1;
|
minimap_auto_start_win_enter = 1;
|
||||||
|
|
||||||
mapleader = "<Space>";
|
mapleader = ";";
|
||||||
};
|
};
|
||||||
|
|
||||||
clipboard = {
|
clipboard = {
|
||||||
@@ -37,9 +37,33 @@
|
|||||||
providers.wl-copy.enable = true;
|
providers.wl-copy.enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
extraConfigVim = ''
|
extraConfigVim = /* vim */ ''
|
||||||
hi Normal guibg=NONE ctermbg=NONE
|
hi Normal guibg=NONE ctermbg=NONE
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
extraConfigLua = /* lua */ ''
|
||||||
|
local Terminal = require('toggleterm.terminal').Terminal
|
||||||
|
local lazygit = Terminal:new({
|
||||||
|
cmd = "lazygit",
|
||||||
|
dir = "git_dir",
|
||||||
|
direction = "float",
|
||||||
|
on_open = function(term)
|
||||||
|
vim.cmd("startinsert!")
|
||||||
|
vim.api.nvim_buf_set_keymap(term.bufnr, "n", "q", "<cmd>close<CR>", {noremap = true, silent = true})
|
||||||
|
end,
|
||||||
|
on_close = function(term)
|
||||||
|
vim.cmd("startinsert!")
|
||||||
|
end,
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
function _lazygit_toggle()
|
||||||
|
lazygit:toggle()
|
||||||
|
end
|
||||||
|
|
||||||
|
vim.api.nvim_set_keymap("n", "<leader>g", "<cmd>lua _lazygit_toggle()<CR>", {noremap = true, silent = true})
|
||||||
|
'';
|
||||||
|
|
||||||
colorschemes.gruvbox = {
|
colorschemes.gruvbox = {
|
||||||
enable = true;
|
enable = true;
|
||||||
trueColor = true;
|
trueColor = true;
|
||||||
@@ -52,7 +76,6 @@
|
|||||||
|
|
||||||
plugins = {
|
plugins = {
|
||||||
lualine.enable = true;
|
lualine.enable = true;
|
||||||
gitblame.enable = true;
|
|
||||||
fidget.enable = true;
|
fidget.enable = true;
|
||||||
indent-blankline = {
|
indent-blankline = {
|
||||||
enable = true;
|
enable = true;
|
||||||
@@ -62,8 +85,13 @@
|
|||||||
nvim-autopairs.enable = true;
|
nvim-autopairs.enable = true;
|
||||||
illuminate.enable = true;
|
illuminate.enable = true;
|
||||||
nvim-colorizer.enable = true;
|
nvim-colorizer.enable = true;
|
||||||
nvim-tree.enable = true;
|
|
||||||
undotree.enable = true;
|
undotree.enable = true;
|
||||||
|
toggleterm = {
|
||||||
|
enable = true;
|
||||||
|
openMapping = "<c-t>";
|
||||||
|
direction = "horizontal";
|
||||||
|
};
|
||||||
|
|
||||||
telescope = {
|
telescope = {
|
||||||
enable = true;
|
enable = true;
|
||||||
keymaps = {
|
keymaps = {
|
||||||
@@ -109,9 +137,9 @@
|
|||||||
nvim-cmp = {
|
nvim-cmp = {
|
||||||
enable = true;
|
enable = true;
|
||||||
mapping = {
|
mapping = {
|
||||||
"<F7>" = "cmp.mapping.select_next_item({behavior = cmp.SelectBehavior.Select})";
|
"<F7>" = /* lua */ "cmp.mapping.select_next_item({behavior = cmp.SelectBehavior.Select})";
|
||||||
"<F5>" = "cmp.mapping.select_prev_item({behavior = cmp.SelectBehavior.Select})";
|
"<F5>" = /* lua */ "cmp.mapping.select_prev_item({behavior = cmp.SelectBehavior.Select})";
|
||||||
"<F6>" = "cmp.mapping.confirm({select = true})";
|
"<F6>" = /* lua */ "cmp.mapping.confirm({select = true})";
|
||||||
};
|
};
|
||||||
sources = [
|
sources = [
|
||||||
{ name = "buffer"; }
|
{ name = "buffer"; }
|
||||||
|
|||||||
@@ -1,19 +0,0 @@
|
|||||||
{ pkgs }:
|
|
||||||
{
|
|
||||||
enable = true;
|
|
||||||
zplug = {
|
|
||||||
enable = true;
|
|
||||||
plugins = [
|
|
||||||
{ name = "plugins/git"; tags = [ from:oh-my-zsh ]; }
|
|
||||||
{ name = "plugins/docker"; tags = [ from:oh-my-zsh ]; }
|
|
||||||
{ name = "plugins/zsh-interactive-cd"; tags = [ from:oh-my-zsh ]; }
|
|
||||||
{ name = "zsh-users/zsh-autosuggestions"; }
|
|
||||||
{ name = "kaplanelad/shellfirm"; }
|
|
||||||
{ name = "zsh-users/zsh-syntax-highlighting"; }
|
|
||||||
{ name = "romkatv/powerlevel10k"; tags = [ as:theme depth:1 ]; }
|
|
||||||
];
|
|
||||||
};
|
|
||||||
initExtra = ''
|
|
||||||
[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh
|
|
||||||
'';
|
|
||||||
}
|
|
||||||
@@ -1,7 +1,11 @@
|
|||||||
|
{ pkgs }:
|
||||||
{
|
{
|
||||||
gpg-agent = {
|
gpg-agent = {
|
||||||
enable = true;
|
enable = true;
|
||||||
enableSshSupport = true;
|
enableSshSupport = true;
|
||||||
pinentryFlavor = "gnome3";
|
pinentryFlavor = "gnome3";
|
||||||
};
|
};
|
||||||
|
# fix pinentry on non-gnome with this in
|
||||||
|
# the system config: services.dbus.packages = with pkgs; [ gcr ];
|
||||||
|
gnome-keyring.enable = true;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user