Compare commits

...

4 Commits

Author SHA1 Message Date
Moritz Böhme b03934b4a3
feat: add vimtex 2024-06-27 10:12:38 +02:00
Moritz Böhme 1a2369c8db
feat: add latexindent formatter 2024-06-24 09:43:55 +02:00
Moritz Böhme d4db0cec27
fix: plantuml-syntax 2024-06-24 09:43:22 +02:00
Moritz Böhme b5b54eb0e7
feat: update hyprland 2024-06-24 09:42:58 +02:00
8 changed files with 145 additions and 59 deletions

View File

@ -72,6 +72,22 @@
"type": "github" "type": "github"
} }
}, },
"cmp-vimtex": {
"flake": false,
"locked": {
"lastModified": 1716040164,
"narHash": "sha256-CO70M+l/9c4vqNm0XloOTzGQTmogHbSwvUFKQxYGsuw=",
"owner": "micangl",
"repo": "cmp-vimtex",
"rev": "a64b1b5eec0460144c91c4f20a45c74b8ded48ae",
"type": "github"
},
"original": {
"owner": "micangl",
"repo": "cmp-vimtex",
"type": "github"
}
},
"darwin": { "darwin": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@ -497,11 +513,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1713612213, "lastModified": 1718450675,
"narHash": "sha256-zJboXgWNpNhKyNF8H/3UYzWkx7w00TOCGKi3cwi+tsw=", "narHash": "sha256-jpsns6buS4bK+1sF8sL8AaixAiCRjA+nldTKvcwmvUs=",
"owner": "hyprwm", "owner": "hyprwm",
"repo": "hyprcursor", "repo": "hyprcursor",
"rev": "cab4746180f210a3c1dd3d53e45c510e309e90e1", "rev": "66d5b46ff94efbfa6fa3d1d1b66735f1779c34a6",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -513,36 +529,39 @@
"hyprland": { "hyprland": {
"inputs": { "inputs": {
"hyprcursor": "hyprcursor", "hyprcursor": "hyprcursor",
"hyprland-protocols": "hyprland-protocols",
"hyprlang": "hyprlang", "hyprlang": "hyprlang",
"hyprutils": "hyprutils",
"hyprwayland-scanner": "hyprwayland-scanner",
"nixpkgs": "nixpkgs_4", "nixpkgs": "nixpkgs_4",
"systems": "systems_4", "systems": "systems_4",
"wlroots": "wlroots",
"xdph": "xdph" "xdph": "xdph"
}, },
"locked": { "locked": {
"lastModified": 1713283263, "lastModified": 1718835324,
"narHash": "sha256-Urb/njWiHYUudXpmK8EKl9Z58esTIG0PxXw5LuM2r5g=", "narHash": "sha256-U5eKTPAXppfSIqKqMIgbyuTBy1gr2seSOUl8sUSR8FE=",
"owner": "hyprwm", "ref": "refs/heads/main",
"repo": "Hyprland", "rev": "fabc30df52ab5d2c369fc8acd4ff909a6ba3b8ac",
"rev": "fe7b748eb668136dd0558b7c8279bfcd7ab4d759", "revCount": 4870,
"type": "github" "submodules": true,
"type": "git",
"url": "https://github.com/hyprwm/Hyprland"
}, },
"original": { "original": {
"owner": "hyprwm", "submodules": true,
"ref": "v0.39.1", "type": "git",
"repo": "Hyprland", "url": "https://github.com/hyprwm/Hyprland"
"type": "github"
} }
}, },
"hyprland-protocols": { "hyprland-protocols": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
"hyprland", "hyprland",
"xdph",
"nixpkgs" "nixpkgs"
], ],
"systems": [ "systems": [
"hyprland", "hyprland",
"xdph",
"systems" "systems"
] ]
}, },
@ -562,6 +581,10 @@
}, },
"hyprlang": { "hyprlang": {
"inputs": { "inputs": {
"hyprutils": [
"hyprland",
"hyprutils"
],
"nixpkgs": [ "nixpkgs": [
"hyprland", "hyprland",
"nixpkgs" "nixpkgs"
@ -572,11 +595,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1713121246, "lastModified": 1717881852,
"narHash": "sha256-502X0Q0fhN6tJK7iEUA8CghONKSatW/Mqj4Wappd++0=", "narHash": "sha256-XeeVoKHQgfKuXoP6q90sUqKyl7EYy3ol2dVZGM+Jj94=",
"owner": "hyprwm", "owner": "hyprwm",
"repo": "hyprlang", "repo": "hyprlang",
"rev": "78fcaa27ae9e1d782faa3ff06c8ea55ddce63706", "rev": "ec6938c66253429192274d612912649a0cfe4d28",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -585,6 +608,56 @@
"type": "github" "type": "github"
} }
}, },
"hyprutils": {
"inputs": {
"nixpkgs": [
"hyprland",
"nixpkgs"
],
"systems": [
"hyprland",
"systems"
]
},
"locked": {
"lastModified": 1718804078,
"narHash": "sha256-CqRZne63BpYlPd/i8lXV0UInUt59oKogiwdVtBRHt60=",
"owner": "hyprwm",
"repo": "hyprutils",
"rev": "4f1351295c55a8f51219b25aa4a6497a067989d0",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "hyprutils",
"type": "github"
}
},
"hyprwayland-scanner": {
"inputs": {
"nixpkgs": [
"hyprland",
"nixpkgs"
],
"systems": [
"hyprland",
"systems"
]
},
"locked": {
"lastModified": 1718119275,
"narHash": "sha256-nqDYXATNkyGXVmNMkT19fT4sjtSPBDS1LLOxa3Fueo4=",
"owner": "hyprwm",
"repo": "hyprwayland-scanner",
"rev": "1419520d5f7f38d35e05504da5c1b38212a38525",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "hyprwayland-scanner",
"type": "github"
}
},
"impermanence": { "impermanence": {
"locked": { "locked": {
"lastModified": 1708968331, "lastModified": 1708968331,
@ -888,11 +961,11 @@
}, },
"nixpkgs_4": { "nixpkgs_4": {
"locked": { "locked": {
"lastModified": 1715087517, "lastModified": 1718530797,
"narHash": "sha256-CLU5Tsg24Ke4+7sH8azHWXKd0CFd4mhLWfhYgUiDBpQ=", "narHash": "sha256-pup6cYwtgvzDpvpSCFh1TEUjw2zkNpk8iolbKnyFmmU=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "b211b392b8486ee79df6cdfb1157ad2133427a29", "rev": "b60ebf54c15553b393d144357375ea956f89e9a9",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -1107,6 +1180,7 @@
"agenix": "agenix", "agenix": "agenix",
"arkenfox-userjs": "arkenfox-userjs", "arkenfox-userjs": "arkenfox-userjs",
"asus-touchpad-numpad-driver": "asus-touchpad-numpad-driver", "asus-touchpad-numpad-driver": "asus-touchpad-numpad-driver",
"cmp-vimtex": "cmp-vimtex",
"devshell": "devshell", "devshell": "devshell",
"disko": "disko", "disko": "disko",
"flake-parts": "flake-parts", "flake-parts": "flake-parts",
@ -1327,29 +1401,9 @@
"type": "github" "type": "github"
} }
}, },
"wlroots": {
"flake": false,
"locked": {
"lastModified": 1713124002,
"narHash": "sha256-vPeZCY+sdiGsz4fl3AVVujfyZyQBz6+vZdkUE4hQ+HI=",
"owner": "hyprwm",
"repo": "wlroots-hyprland",
"rev": "611a4f24cd2384378f6e500253983107c6656c64",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "wlroots-hyprland",
"rev": "611a4f24cd2384378f6e500253983107c6656c64",
"type": "github"
}
},
"xdph": { "xdph": {
"inputs": { "inputs": {
"hyprland-protocols": [ "hyprland-protocols": "hyprland-protocols",
"hyprland",
"hyprland-protocols"
],
"hyprlang": [ "hyprlang": [
"hyprland", "hyprland",
"hyprlang" "hyprlang"
@ -1364,11 +1418,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1714662532, "lastModified": 1718619174,
"narHash": "sha256-Pj2xGSYhapYbXL7sk7TTlOtCZcTfPQoL3fPbZeg7L4Y=", "narHash": "sha256-FWW68AVYmB91ZDQnhLMBNCUUTCjb1ZpO2k2KIytHtkA=",
"owner": "hyprwm", "owner": "hyprwm",
"repo": "xdg-desktop-portal-hyprland", "repo": "xdg-desktop-portal-hyprland",
"rev": "1f228ba2f1f254195c0b571302b37482861abee3", "rev": "c7894aa54f9a7dbd16df5cd24d420c8af22d5623",
"type": "github" "type": "github"
}, },
"original": { "original": {

View File

@ -45,6 +45,8 @@
hawtkeys-nvim.url = "github:tris203/hawtkeys.nvim"; hawtkeys-nvim.url = "github:tris203/hawtkeys.nvim";
none-ls-shellcheck-nvim.flake = false; none-ls-shellcheck-nvim.flake = false;
none-ls-shellcheck-nvim.url = "github:gbprod/none-ls-shellcheck.nvim"; none-ls-shellcheck-nvim.url = "github:gbprod/none-ls-shellcheck.nvim";
cmp-vimtex.flake = false;
cmp-vimtex.url = "github:micangl/cmp-vimtex";
# river # river
river.url = "git+https://github.com/riverwm/river?submodules=1"; river.url = "git+https://github.com/riverwm/river?submodules=1";
@ -52,7 +54,11 @@
# Hyprland # Hyprland
hypr-contrib.url = "github:hyprwm/contrib"; hypr-contrib.url = "github:hyprwm/contrib";
hyprland.url = "github:hyprwm/Hyprland/v0.39.1"; hyprland = {
type = "git";
url = "https://github.com/hyprwm/Hyprland";
submodules = true;
};
# Laptop # Laptop
asus-touchpad-numpad-driver.url = "github:MoritzBoehme/asus-touchpad-numpad-driver/german-layout"; asus-touchpad-numpad-driver.url = "github:MoritzBoehme/asus-touchpad-numpad-driver/german-layout";

View File

@ -50,9 +50,9 @@ in
layout = dwindle layout = dwindle
} }
cursor { # cursor {
inactive_timeout = 1 # inactive_timeout = 1
} # }
decoration { decoration {
# See https://wiki.hyprland.org/Configuring/Variables/ for more # See https://wiki.hyprland.org/Configuring/Variables/ for more

View File

@ -16,6 +16,11 @@ in
source = ./plugins/snippets; source = ./plugins/snippets;
}; };
home.packages = with pkgs; [
xdotool
];
programs.neovim = { programs.neovim = {
enable = true; enable = true;
package = inputs.neovim-nightly-overlay.packages.${pkgs.system}.default; package = inputs.neovim-nightly-overlay.packages.${pkgs.system}.default;

View File

@ -36,10 +36,17 @@ in
{ plugin = pkgs.vimPlugins.cmp-async-path; } { plugin = pkgs.vimPlugins.cmp-async-path; }
{ plugin = pkgs.vimPlugins.cmp-buffer; } { plugin = pkgs.vimPlugins.cmp-buffer; }
{ plugin = pkgs.vimPlugins.cmp-cmdline; } { plugin = pkgs.vimPlugins.cmp-cmdline; }
{ plugin = pkgs.vimPlugins.cmp-nvim-lsp; }
{ plugin = pkgs.vimPlugins.cmp_luasnip; }
{ plugin = pkgs.vimPlugins.cmp-spell; }
{ plugin = pkgs.vimPlugins.cmp-nvim-lsp-signature-help; } { plugin = pkgs.vimPlugins.cmp-nvim-lsp-signature-help; }
{ plugin = pkgs.vimPlugins.cmp-nvim-lsp; }
{ plugin = pkgs.vimPlugins.cmp-spell; }
{
plugin = pkgs.vimUtils.buildVimPlugin {
pname = "cmp-vimtex";
version = lib.my.mkVersionInput inputs.cmp-vimtex;
src = inputs.cmp-vimtex;
};
}
{ plugin = pkgs.vimPlugins.cmp_luasnip; }
{ {
plugin = pkgs.vimPlugins.copilot-cmp; plugin = pkgs.vimPlugins.copilot-cmp;
opts = { }; opts = { };
@ -210,6 +217,18 @@ in
cmd = [ "ConformInfo" "Format" ]; cmd = [ "ConformInfo" "Format" ];
conf = readFile ./lua/conform.lua; conf = readFile ./lua/conform.lua;
} }
{ plugin = plantuml-syntax; } { plugin = pkgs.vimPlugins.plantuml-syntax; }
{
plugin = pkgs.vimPlugins.vimtex;
lazy = false;
conf = /* lua */ ''
vim.g.vimtex_view_method = "zathura"
vim.g.vimtex_mappings_disable = vim.fn.executable("texlab") == 1 and { ["n"] = { "K" } } or {} -- disable `K` as it conflicts with LSP hover
vim.g.vimtex_quickfix_method = vim.fn.executable("pplatex") == 1 and "pplatex" or "latexlog"
'';
keys = [
{ key = "<localleader>l"; cmd = ""; desc = "+vimtex"; }
];
}
]; ];
} }

View File

@ -2,6 +2,7 @@ local conform = require("conform")
local formatters_by_ft = { local formatters_by_ft = {
["*"] = { "codespell", "trim_whitespace" }, ["*"] = { "codespell", "trim_whitespace" },
gleam = { "gleam" },
go = { "gofmt" }, go = { "gofmt" },
json = { "jq" }, json = { "jq" },
lua = { "stylua" }, lua = { "stylua" },
@ -9,9 +10,9 @@ local formatters_by_ft = {
python = { { "ruff_fix", "isort" }, { "ruff_format", "black" } }, python = { { "ruff_fix", "isort" }, { "ruff_format", "black" } },
rust = { "rustfmt" }, rust = { "rustfmt" },
sh = { "shfmt" }, sh = { "shfmt" },
tex = { "latexindent" },
toml = { "taplo" }, toml = { "taplo" },
yaml = { "yamlfix" }, yaml = { "yamlfix" },
gleam = { "gleam" },
} }
conform.setup({ conform.setup({

View File

@ -69,6 +69,7 @@ cmp.setup({
{ priority = 3, name = "copilot" }, { priority = 3, name = "copilot" },
{ priority = 3, name = "nvim_lsp_signature_help" }, { priority = 3, name = "nvim_lsp_signature_help" },
{ priority = 4, name = "luasnip" }, { priority = 4, name = "luasnip" },
{ priority = 4, name = "vimtex" },
}), }),
}) })

View File

@ -1,8 +1,7 @@
{ pkgs, ... }: { pkgs, ... }:
with builtins;
{ {
config.home-manager.users.moritz.programs.neovim.lazy.plugins = with pkgs.vimPlugins; [ config.home-manager.users.moritz.programs.neovim.lazy.plugins = [
( (
let let
parserDir = pkgs.symlinkJoin { parserDir = pkgs.symlinkJoin {
@ -11,13 +10,14 @@ with builtins;
}; };
in in
{ {
plugin = nvim-treesitter; plugin = pkgs.vimPlugins.nvim-treesitter;
event = [ "BufReadPost" "BufNewFile" ]; event = [ "BufReadPost" "BufNewFile" ];
opts = { opts = {
sync_install = false; sync_install = false;
auto_install = false; auto_install = false;
highlight = { highlight = {
enable = true; enable = true;
disable = [ "latex" ];
}; };
textobjects = textobjects =
{ {
@ -60,8 +60,8 @@ with builtins;
''; '';
priority = 100; priority = 100;
dependencies = [ dependencies = [
{ plugin = nvim-treesitter-textobjects; } { plugin = pkgs.vimPlugins.nvim-treesitter-textobjects; }
{ plugin = nvim-ts-context-commentstring; opts = { }; } { plugin = pkgs.vimPlugins.nvim-ts-context-commentstring; opts = { }; }
]; ];
} }
) )