general fixes plus nvim transparent
This commit is contained in:
parent
3ce2c4f098
commit
df229f0856
@ -167,11 +167,11 @@
|
||||
},
|
||||
"nur": {
|
||||
"locked": {
|
||||
"lastModified": 1697620530,
|
||||
"narHash": "sha256-yP1UqYQXHrA7QmXUHqlx9lVEBjzmtLPOJwmEk8fyUeY=",
|
||||
"lastModified": 1697637981,
|
||||
"narHash": "sha256-BReinxzdLksrjXkCZWqHZSEKd4/vWuNwgzmfjKprRxo=",
|
||||
"owner": "nix-community",
|
||||
"repo": "NUR",
|
||||
"rev": "51314cbd9e37c1ed544e336b60a0ac73e1709a13",
|
||||
"rev": "bc8feb3239c1a4a896fd03ada155d1b8ee8ae38c",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -16,7 +16,7 @@
|
||||
nur.url = "github:nix-community/NUR";
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs, home-manager, ...}@inputs:
|
||||
outputs = { self, nixpkgs, home-manager, nur, ...}@inputs:
|
||||
let
|
||||
system = "x86_64-linux";
|
||||
username = "nicolaivds";
|
||||
|
@ -1,9 +1,18 @@
|
||||
{ inputs, pkgs, ... }:
|
||||
{ inputs, pkgs, lib, ... }:
|
||||
{
|
||||
programs.neovim =
|
||||
let
|
||||
toLua = str: "lua << EOF\n${str}\nEOF\n";
|
||||
toLuaFile = file: "lua << EOF\n${builtins.readFile file}\nEOF\n";
|
||||
fromGitHub = rev: ref: repo: pkgs.vimUtils.buildVimPlugin {
|
||||
pname = "${lib.strings.sanitizeDerivationName repo}";
|
||||
version = ref;
|
||||
src = builtins.fetchGit {
|
||||
url = "https://github.com/${repo}.git";
|
||||
ref = ref;
|
||||
rev = rev;
|
||||
};
|
||||
};
|
||||
in
|
||||
{
|
||||
enable = true;
|
||||
@ -14,31 +23,31 @@
|
||||
|
||||
defaultEditor = true;
|
||||
|
||||
plugins = with pkgs.vimPlugins; [
|
||||
plugins = with pkgs; [
|
||||
# Colorschemes
|
||||
{
|
||||
plugin = catppuccin-nvim;
|
||||
plugin = vimPlugins.catppuccin-nvim;
|
||||
config = toLuaFile ./plugins/colorschemes/catppuccin.lua;
|
||||
}
|
||||
|
||||
# LSP
|
||||
{
|
||||
plugin = nvim-lspconfig;
|
||||
plugin = vimPlugins.nvim-lspconfig;
|
||||
config = toLuaFile ./plugins/lsp.lua;
|
||||
}
|
||||
|
||||
cmp-buffer
|
||||
cmp-cmdline
|
||||
cmp-nvim-lsp
|
||||
cmp-nvim-lua
|
||||
cmp-path
|
||||
cmp_luasnip
|
||||
luasnip
|
||||
nvim-cmp
|
||||
vimPlugins.cmp-buffer
|
||||
vimPlugins.cmp-cmdline
|
||||
vimPlugins.cmp-nvim-lsp
|
||||
vimPlugins.cmp-nvim-lua
|
||||
vimPlugins.cmp-path
|
||||
vimPlugins.cmp_luasnip
|
||||
vimPlugins.luasnip
|
||||
vimPlugins.nvim-cmp
|
||||
|
||||
# The rest
|
||||
{
|
||||
plugin = indent-blankline-nvim;
|
||||
plugin = vimPlugins.indent-blankline-nvim;
|
||||
config = toLuaFile ./plugins/indent.lua;
|
||||
}
|
||||
|
||||
@ -46,22 +55,28 @@
|
||||
|
||||
# TODO: enable this when treesitter is installed
|
||||
# {
|
||||
# plugin = nvim-ts-autotag;
|
||||
# plugin = vimPlugins.nvim-ts-autotag;
|
||||
# config = toLuaFile ./plugins/autotag.lua;
|
||||
# }
|
||||
|
||||
{
|
||||
plugin = nvim-colorizer-lua;
|
||||
plugin = vimPlugins.nvim-colorizer-lua;
|
||||
config = toLuaFile ./plugins/colorizer.lua;
|
||||
}
|
||||
|
||||
# GIT
|
||||
{
|
||||
plugin = gitsigns-nvim;
|
||||
plugin = vimPlugins.gitsigns-nvim;
|
||||
config = toLuaFile ./plugins/gitsigns.lua;
|
||||
}
|
||||
|
||||
vim-fugitive
|
||||
vimPlugins.vim-fugitive
|
||||
|
||||
{
|
||||
plugin = (fromGitHub "3af6232c8d39d51062702e875ff6407c1eeb0391" "main" "xiyaowong/transparent.nvim");
|
||||
config = toLuaFile ./plugins/transparent.lua
|
||||
}
|
||||
|
||||
|
||||
];
|
||||
|
||||
|
34
nix/users/base/neovim/plugins/transparent.lua
Normal file
34
nix/users/base/neovim/plugins/transparent.lua
Normal file
@ -0,0 +1,34 @@
|
||||
local status, plugin = pcall(require, 'transparent')
|
||||
if not status then
|
||||
print('Plugin Error: ', plugin)
|
||||
return
|
||||
end
|
||||
|
||||
plugin.setup({
|
||||
groups = { -- table: default groups
|
||||
'Normal', 'NormalNC', 'Comment', 'Constant', 'Special', 'Identifier',
|
||||
'Statement', 'PreProc', 'Type', 'Underlined', 'Todo', 'String', 'Function',
|
||||
'Conditional', 'Repeat', 'Operator', 'Structure', 'LineNr', 'NonText',
|
||||
'SignColumn', 'CursorLineNr', 'EndOfBuffer',
|
||||
},
|
||||
extra_groups = {
|
||||
"NormalFloat", -- plugins which have float panel such as Lazy, Mason, LspInfo
|
||||
"NvimTreeNormal", -- NvimTree
|
||||
"NvimTreeNormalNC",
|
||||
"NvimTreeWinSeparator",
|
||||
"TelescopeNormal",
|
||||
"TelescopeBorder",
|
||||
"WhichKeyFloat",
|
||||
}, -- table: additional groups that should be cleared
|
||||
exclude_groups = {}, -- table: groups you don't want to clear
|
||||
})
|
||||
vim.g.transparent_groups = vim.list_extend(
|
||||
vim.g.transparent_groups or {},
|
||||
vim.tbl_map(function(v)
|
||||
return v.hl_group
|
||||
end, vim.tbl_values(require('bufferline.config').highlights))
|
||||
)
|
||||
|
||||
--- Fix for bufferline looking strange on startup ---
|
||||
vim.cmd(":TransparentToggle")
|
||||
vim.cmd(":TransparentToggle")
|
@ -16,6 +16,7 @@ in
|
||||
{
|
||||
_module.args = { inherit inputs username custom; };
|
||||
imports = [
|
||||
inputs.nur.hmModules.nur
|
||||
./general
|
||||
./programs
|
||||
./themes
|
||||
|
@ -2,6 +2,7 @@
|
||||
{
|
||||
#Overlays/Overrides
|
||||
nixpkgs.overlays = [
|
||||
inputs.nur.overlay
|
||||
(self: super: {
|
||||
waybar = super.waybar.overrideAttrs (oldAttrs: {
|
||||
mesonFlags = oldAttrs.mesonFlags ++ [ "-Dexperimental=true" ];
|
||||
@ -27,6 +28,8 @@
|
||||
hplipWithPlugin
|
||||
inputs.maxfetch.packages.${pkgs.system}.default
|
||||
inputs.orcaslicer.packages.${pkgs.system}.orca-slicer
|
||||
jellycli
|
||||
jftui
|
||||
libreoffice
|
||||
lutris
|
||||
mpv
|
||||
|
Loading…
Reference in New Issue
Block a user