This commit is contained in:
Varris 2023-05-14 11:23:49 +02:00
parent ae659b2df2
commit f3bc74c085
9 changed files with 205 additions and 204 deletions

View File

@ -20,11 +20,6 @@
};
# Fish Plugins End
nixvim = {
url = "github:pta2002/nixvim";
inputs.nixpkgs.follows = "nixpkgs";
};
friendly-snippets = {
url = "github:rafamadriz/friendly-snippets";
flake = false;
@ -72,11 +67,6 @@
flake = false;
};
webcord = {
url = "github:fufexan/webcord-flake";
inputs.nixpkgs.follows = "nixpkgs";
};
gruvbox-kvantum = {
url = "github:thefallnn/Gruvbox-Kvantum";
flake = false;
@ -103,7 +93,6 @@
inputs.hyprland-contrib.overlays.default
inputs.hyprpaper.overlays.default
inputs.hyprpicker.overlays.default
inputs.webcord.overlays.default
];
};
in

View File

@ -16,14 +16,12 @@
kernelParams =
[
"amdgpu.ppfeaturemask=0xffffffff"
"drm.edid_firmware=DP-1:edid/edid-EX2780Q.bin"
"net.ifnames=0"
"net.ifnames=0"
];
extraModprobeConfig = ''
options iwlmvm power_scheme=1
options iwlwifi power_save=0
options cfg80211 cfg80211_disable_40mhz_24ghz=Y
'';
loader = {
@ -145,19 +143,21 @@
systemPackages = [
pkgs.bc
pkgs.distrobox
pkgs.git
pkgs.links2
pkgs.ripgrep
pkgs.file
pkgs.fd
pkgs.file
pkgs.git
pkgs.htop
pkgs.links2
pkgs.libsForQt5.dolphin
pkgs.libsForQt5.kio-extras
pkgs.lm_sensors
pkgs.nvtop-amd
pkgs.openrgb
pkgs.unzip
pkgs.unrar
pkgs.p7zip
pkgs.pciutils
pkgs.ripgrep
pkgs.unrar
pkgs.unzip
pkgs.usbutils
];
};

View File

@ -7,7 +7,7 @@
directory = "/mnt/hdd/Music";
library = "/mnt/hdd/Music/library.db";
asciify_paths = true;
# asciify_paths = true;
import = {
"write" = true;

View File

@ -36,12 +36,7 @@
ec = ''
pushd . &> /dev/null
cd "${config.home.homeDirectory}/.dotfiles"
set "filename" (${pkgs.fd}/bin/fd -t f . ~/.dotfiles | \
${pkgs.fzf}/bin/fzf -q "$argv[1]" \
--preview "${pkgs.python3Packages.pygments}/bin/pygmentize -g -O linenos=1 {}")
if test -f "$filename"
$EDITOR $filename
end
nvim "+Telescope find_files"
popd
'';

View File

@ -1,184 +1,32 @@
{ config, pkgs, lib, inputs, ... }:
let
colors = config.colorScheme.colors;
in
{
imports = [
inputs.nixvim.homeManagerModules.nixvim
];
programs.nixvim = {
enable = true;
globals = {
mapleader = ",";
};
clipboard.register = "unnamedplus";
colorschemes.gruvbox = {
enable = true;
transparentBg = true;
};
autoCmd = [
{
event = [ "VimEnter" ];
pattern = [ "*" ];
command = "hi! Normal ctermbg=NONE guibg=NONE";
}
{
event = [ "BufWinLeave" ] ;
pattern = [ "*" ];
command = "silent! mkview";
}
{
event = [ "BufWinEnter" ] ;
pattern = [ "*" ];
command = "silent! loadview";
}
];
options = {
number = true;
relativenumber = true;
ignorecase = true;
smartcase = true;
tabstop = 2;
shiftwidth = 2;
expandtab = true;
autoindent = true;
listchars = "tab:!·,trail:·";
};
plugins = {
intellitab.enable = true;
airline = {
programs.neovim = {
enable = true;
powerline = true;
theme = "base16_gruvbox_dark_medium";
};
lsp.servers = {
clangd.enable = true;
rnix-lsp.enable = true;
bashls.enable = true;
};
plugins = with pkgs.vimPlugins; [
gruvbox-nvim
nvim-web-devicons
lualine-nvim
bufferline-nvim
nvim-colorizer-lua
nvim-autopairs
comment-nvim
neo-tree-nvim
nvim-notify
nvim-treesitter.withAllGrammars
comment-nvim.enable = true;
telescope-nvim
telescope-fzf-native-nvim
fugitive.enable = true;
lsp = {
enable = true;
keymaps.lspBuf = {
K = "hover";
gD = "references";
gd = "definition";
gi = "implementation";
gt = "type_definition";
};
};
nvim-autopairs.enable = true;
lspkind = {
enable = true;
cmp = {
enable = true;
};
};
cmp-treesitter.enable = true;
luasnip = {
enable = true;
fromVscode = [
{ paths = inputs.friendly-snippets.outPath; }
];
};
cmp_luasnip.enable = true;
cmp-cmdline.enable = true;
nvim-cmp = {
enable = true;
sources = [
{ name = "nvim_lsp"; }
{ name = "luasnip";}
{ name = "path"; }
{ name = "buffer"; }
{ name = "grammar"; }
nvim-cmp
lspkind-nvim
cmp-cmdline
cmp-path
cmp-buffer
cmp-nvim-lsp
];
mappingPresets = [ "insert" ];
mapping = {
"<CR>" = "cmp.mapping.confirm({ select = true })";
"<C-b>" = "cmp.mapping.scroll_docs(-4)";
"<C-f>" = "cmp.mapping.scroll_docs(4)";
"<C-Space>" = "cmp.mapping.complete()";
"<C-e>" = "cmp.mapping.abort()";
};
window.completion = {
border = "single";
scrollbar = true;
winhighlight = "Normal:Pmenu,FloatBorder:Pmenu,CursorLine:PmenuSel,Search:None";
};
window.documentation = {
border = "single";
winhighlight = "Normal:Pmenu,FloatBorder:Pmenu,CursorLine:PmenuSel,Search:None";
};
};
nvim-colorizer.enable = true;
nvim-lightbulb.enable = true;
neo-tree.enable = true;
telescope = {
enable = true;
keymaps = {
"<leader>c" = "git_files";
"<leader>v" = "live_grep";
};
};
treesitter = {
enable = true;
indent = true;
};
bufferline = {
enable = true;
separatorStyle = "slant";
};
indent-blankline = {
enable = true;
useTreesitter = true;
useTreesitterScope = true;
};
extraLuaConfig = builtins.readFile ./init.lua;
};
maps = {
normal."<C-n>" = {
silent = true;
action = "<cmd>NeoTreeFocusToggle<CR>";
};
normal."<mapleader><Space>" = {
silent = true;
action = "<cmd>nohlsearch<CR>";
};
};
};
}

View File

@ -0,0 +1,165 @@
vim.g.mapleader = ","
-- 4 space tabs
vim.o.expandtab = true
vim.o.shiftwidth = 4
vim.o.tabstop = 4
vim.o.smartindent = true
vim.o.clipboard = "unnamedplus"
vim.o.termguicolors = true
vim.o.ignorecase = true
vim.o.smartcase = true
vim.o.lazyredraw = true
vim.wo.number = true
vim.wo.relativenumber = true
require("gruvbox").setup()
vim.cmd("colorscheme gruvbox")
require("lualine").setup({
options = {
theme = "gruvbox"
}
})
require("bufferline").setup({
options = {
separator_style = "slant",
show_tab_indicators = true,
}
})
require("colorizer").setup()
require("nvim-autopairs").setup()
require("Comment").setup()
require("neo-tree").setup({
default_component_configs = {
icon = {
folder_empty = "󰜌",
folder_empty_open = "󰜌",
},
git_status = {
symbols = {
renamed = "󰁕",
unstaged = "󰄱",
},
},
},
document_symbols = {
kinds = {
File = { icon = "󰈙", hl = "Tag" },
Namespace = { icon = "󰌗", hl = "Include" },
Package = { icon = "󰏖", hl = "Label" },
Class = { icon = "󰌗", hl = "Include" },
Property = { icon = "󰆧", hl = "@property" },
Enum = { icon = "󰒻", hl = "@number" },
Function = { icon = "󰊕", hl = "Function" },
String = { icon = "󰀬", hl = "String" },
Number = { icon = "󰎠", hl = "Number" },
Array = { icon = "󰅪", hl = "Type" },
Object = { icon = "󰅩", hl = "Type" },
Key = { icon = "󰌋", hl = "" },
Struct = { icon = "󰌗", hl = "Type" },
Operator = { icon = "󰆕", hl = "Operator" },
TypeParameter = { icon = "󰊄", hl = "Type" },
StaticMethod = { icon = '󰠄 ', hl = 'Function' },
}
},
})
vim.keymap.set("n", "<C-n>", "<cmd>NeoTreeFocusToggle<CR>")
require("nvim-treesitter.configs").setup({
highlight = { enable = true, },
})
local builtin = require("telescope.builtin")
vim.keymap.set('n', '<leader>ff', builtin.find_files, {})
vim.keymap.set('n', '<leader>fg', builtin.live_grep, {})
vim.keymap.set('n', '<leader>fb', builtin.buffers, {})
vim.keymap.set('n', '<leader>fh', builtin.help_tags, {})
local cmp = require("cmp")
local lspkind = require("lspkind")
cmp.setup({
preselect = cmp.PreselectMode.None,
formatting = {
format = lspkind.cmp_format ({
mode = "symbol",
maxwidth = 50,
ellipsis_char = "...",
symbol_map = {
Text = "󰉿",
Method = "󰆧",
Function = "󰊕",
Constructor = "",
Field = "",
Variable = "󰀫",
Class = "",
Interface = "",
Module = "",
Property = "",
Unit = "",
Value = "󰎠",
Enum = "",
Keyword = "󰌋",
Snippet = "",
Color = "󰏘",
File = "󰈙",
Reference = "󰈇",
Folder = "󰉋",
EnumMember = "",
Constant = "󰏿",
Struct = "",
Event = "",
Operator = "󰆕",
TypeParameter = ""
},
}),
},
window = {
completion = cmp.config.window.bordered(),
documentation = cmp.config.window.bordered(),
},
sources = cmp.config.sources ({
{ name = "buffer" },
{ name = "path" },
{ name = "nvim_lsp" },
}),
mapping = cmp.mapping.preset.insert({
['<C-b>'] = cmp.mapping.scroll_docs(-4),
['<C-f>'] = cmp.mapping.scroll_docs(4),
['<C-Space>'] = cmp.mapping.complete(),
['<C-e>'] = cmp.mapping.abort(),
['<CR>'] = cmp.mapping.confirm({ select = false }),
}),
})
local cmp_autopairs = require('nvim-autopairs.completion.cmp')
cmp.event:on(
'confirm_done',
cmp_autopairs.on_confirm_done()
)
cmp.setup.cmdline(":", {
mapping = cmp.mapping.preset.cmdline(),
sources = cmp.config.sources({
{ name = "path" },
{ name = "cmdline" },
})
})
cmp.setup.cmdline("/", {
mapping = cmp.mapping.preset.cmdline(),
sources = cmp.config.sources({
{ name = "buffer" },
})
})

View File

@ -208,6 +208,7 @@ in
layerrule = blur, notifications
windowrulev2 = fullscreen, class:^(hl2_linux)$
windowrulev2 = float, class:^(org.kde.dolphin)$
'';
};

View File

@ -8,15 +8,15 @@ in
anchor = "top-right";
defaultTimeout = 5000;
width = 320;
height = 130;
width = 440;
height = 320;
backgroundColor = "#${colors.base00}B3";
borderColor = "#${colors.base01}";
borderRadius = 10;
borderSize = 2;
font = "JetBrainsMono Nerd Font Regular 9";
font = "JetBrainsMono Nerd Font Regular 10";
};
}

View File

@ -28,6 +28,8 @@ in
bc
bottom
calcurse
libsForQt5.dolphin
libsForQt5.dolphin-plugins
gimp
gnome.file-roller
gnome.gvfs
@ -39,6 +41,7 @@ in
noto-fonts-cjk-sans
noto-fonts-cjk-serif
obs-studio
openxray
openmw
pavucontrol
protontricks
@ -55,7 +58,7 @@ in
vimv
vulkan-tools
vulkan-validation-layers
webcord
webcord-vencord
wineWowPackages.stagingFull
wxedid
xdg-utils