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"
|
||||
"swww init"
|
||||
"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"
|
||||
"${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; };
|
||||
services = import ./services.nix;
|
||||
services = import ./services.nix { inherit pkgs; };
|
||||
|
||||
home.file.".p10k.zsh".source = ./programs/.p10k.zsh;
|
||||
}
|
||||
|
||||
@@ -56,4 +56,5 @@
|
||||
|
||||
# utils
|
||||
neofetch
|
||||
pinentry-gnome
|
||||
]
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
};
|
||||
|
||||
keymaps = [
|
||||
{ key = "<F9>"; mode = "n"; action = "<cmd>:UndotreeToggle<CR>"; }
|
||||
{ key = "<leader>u"; mode = "n"; action = "<cmd>:UndotreeToggle<CR>"; }
|
||||
];
|
||||
|
||||
globals = {
|
||||
@@ -29,7 +29,7 @@
|
||||
minimap_auto_start = 1;
|
||||
minimap_auto_start_win_enter = 1;
|
||||
|
||||
mapleader = "<Space>";
|
||||
mapleader = ";";
|
||||
};
|
||||
|
||||
clipboard = {
|
||||
@@ -37,9 +37,33 @@
|
||||
providers.wl-copy.enable = true;
|
||||
};
|
||||
|
||||
extraConfigVim = ''
|
||||
extraConfigVim = /* vim */ ''
|
||||
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 = {
|
||||
enable = true;
|
||||
trueColor = true;
|
||||
@@ -52,7 +76,6 @@
|
||||
|
||||
plugins = {
|
||||
lualine.enable = true;
|
||||
gitblame.enable = true;
|
||||
fidget.enable = true;
|
||||
indent-blankline = {
|
||||
enable = true;
|
||||
@@ -62,8 +85,13 @@
|
||||
nvim-autopairs.enable = true;
|
||||
illuminate.enable = true;
|
||||
nvim-colorizer.enable = true;
|
||||
nvim-tree.enable = true;
|
||||
undotree.enable = true;
|
||||
toggleterm = {
|
||||
enable = true;
|
||||
openMapping = "<c-t>";
|
||||
direction = "horizontal";
|
||||
};
|
||||
|
||||
telescope = {
|
||||
enable = true;
|
||||
keymaps = {
|
||||
@@ -109,9 +137,9 @@
|
||||
nvim-cmp = {
|
||||
enable = true;
|
||||
mapping = {
|
||||
"<F7>" = "cmp.mapping.select_next_item({behavior = cmp.SelectBehavior.Select})";
|
||||
"<F5>" = "cmp.mapping.select_prev_item({behavior = cmp.SelectBehavior.Select})";
|
||||
"<F6>" = "cmp.mapping.confirm({select = true})";
|
||||
"<F7>" = /* lua */ "cmp.mapping.select_next_item({behavior = cmp.SelectBehavior.Select})";
|
||||
"<F5>" = /* lua */ "cmp.mapping.select_prev_item({behavior = cmp.SelectBehavior.Select})";
|
||||
"<F6>" = /* lua */ "cmp.mapping.confirm({select = true})";
|
||||
};
|
||||
sources = [
|
||||
{ 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 = {
|
||||
enable = true;
|
||||
enableSshSupport = true;
|
||||
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