nvim updates
Lint / lint (push) Failing after 1m28s Details
Plex Update / update (push) Successful in 1m47s Details

reboot
Vivian 2023-12-06 22:03:27 +01:00
parent cf2f967696
commit 1ec8d8517b
3 changed files with 92 additions and 127 deletions

View File

@ -63,29 +63,6 @@
"type": "github"
}
},
"beautysh": {
"inputs": {
"nixpkgs": [
"nixvim",
"nixpkgs"
],
"poetry2nix": "poetry2nix",
"utils": "utils_3"
},
"locked": {
"lastModified": 1680308980,
"narHash": "sha256-aUEHV0jk2qIFP3jlsWYWhBbm+w/N9gzH3e4I5DcdB5s=",
"owner": "lovesegfault",
"repo": "beautysh",
"rev": "9845efc3ea3e86cc0d41465d720a47f521b2799c",
"type": "github"
},
"original": {
"owner": "lovesegfault",
"repo": "beautysh",
"type": "github"
}
},
"blobs": {
"flake": false,
"locked": {
@ -243,7 +220,7 @@
"webcord",
"nixpkgs"
],
"poetry2nix": "poetry2nix_2",
"poetry2nix": "poetry2nix",
"pre-commit-hooks": "pre-commit-hooks_2"
},
"locked": {
@ -525,11 +502,11 @@
"systems": "systems_3"
},
"locked": {
"lastModified": 1694529238,
"narHash": "sha256-zsNZZGTGnMOf9YpHKJqMSsa0dXbfmxeoJ7xHlrt+xmY=",
"lastModified": 1701680307,
"narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "ff7b65b44d01cf9ba6a71320833626af21126384",
"rev": "4022d587cbbfd70fe950c1e2083a02621806a725",
"type": "github"
},
"original": {
@ -687,11 +664,11 @@
]
},
"locked": {
"lastModified": 1701433070,
"narHash": "sha256-Gf9JStfENaUQ7YWFz3V7x/srIwr4nlnVteqaAxtwpgM=",
"lastModified": 1701728041,
"narHash": "sha256-x0pyrI1vC8evVDxCxyO6olOyr4wlFg9+VS3C3p4xFYQ=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "4a8545f5e737a6338814a4676dc8e18c7f43fc57",
"rev": "ac7216918cd65f3824ba7817dea8f22e61221eaf",
"type": "github"
},
"original": {
@ -713,11 +690,11 @@
"rust-overlay": "rust-overlay_2"
},
"locked": {
"lastModified": 1701284014,
"narHash": "sha256-k/7fo0a/G8T6NYtIFTv1MPE9oxiLeiXONgvWfGmkeOs=",
"lastModified": 1701686621,
"narHash": "sha256-OAR4jhfldEGuXH8DB9w8YrFLcEsZsApWdYPsmJHwM/E=",
"owner": "nix-community",
"repo": "lanzaboote",
"rev": "43582b56cfd104e5944d38166839d10c7a0d292f",
"rev": "5655251a38f2a31f26aebae3e0d7fe0f5bd74683",
"type": "github"
},
"original": {
@ -883,11 +860,11 @@
]
},
"locked": {
"lastModified": 1696058303,
"narHash": "sha256-eNqKWpF5zG0SrgbbtljFOrRgFgRzCc4++TMFADBMLnc=",
"lastModified": 1701689616,
"narHash": "sha256-ewnfgvRy73HoP5KnYmy1Rcr4m4yShvsb6TCCaKoW8pc=",
"owner": "nix-community",
"repo": "nixos-generators",
"rev": "150f38bd1e09e20987feacb1b0d5991357532fb5",
"rev": "246219bc21b943c6f6812bb7744218ba0df08600",
"type": "github"
},
"original": {
@ -898,11 +875,11 @@
},
"nixos-hardware": {
"locked": {
"lastModified": 1701250978,
"narHash": "sha256-ohu3cz4edjpGxs2qUTgbs0WrnewOX4crnUJNEB6Jox4=",
"lastModified": 1701656485,
"narHash": "sha256-xDFormrGCKKGqngHa2Bz1GTeKlFMMjLnHhTDRdMJ1hs=",
"owner": "nixos",
"repo": "nixos-hardware",
"rev": "8772491ed75f150f02552c60694e1beff9f46013",
"rev": "fa194fc484fd7270ab324bb985593f71102e84d1",
"type": "github"
},
"original": {
@ -1089,11 +1066,11 @@
},
"nixpkgs_4": {
"locked": {
"lastModified": 1701368325,
"narHash": "sha256-3OqZyi2EdopJxpxwrySPyCTuCvfBY4oXTLVgQ4B6qDg=",
"lastModified": 1701653742,
"narHash": "sha256-9bLa7tsNtFSsXZDC+XVHyT6auJxUY+gObkvnEgSV7TM=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "3934dbde4f4a0e266825348bc4ad1bdd00a8d6a3",
"rev": "d08f6384a5d8e5cf28ab243752cd83eed2a5d700",
"type": "github"
},
"original": {
@ -1104,11 +1081,11 @@
},
"nixpkgs_5": {
"locked": {
"lastModified": 1701068326,
"narHash": "sha256-vmMceA+q6hG1yrjb+MP8T0YFDQIrW3bl45e7z24IEts=",
"lastModified": 1701436327,
"narHash": "sha256-tRHbnoNI8SIM5O5xuxOmtSLnswEByzmnQcGGyNRjxsE=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "8cfef6986adfb599ba379ae53c9f5631ecd2fd9c",
"rev": "91050ea1e57e50388fa87a3302ba12d188ef723a",
"type": "github"
},
"original": {
@ -1184,11 +1161,11 @@
},
"nixpkgs_stable": {
"locked": {
"lastModified": 1701362232,
"narHash": "sha256-GVdzxL0lhEadqs3hfRLuj+L1OJFGiL/L7gCcelgBlsw=",
"lastModified": 1701615100,
"narHash": "sha256-7VI84NGBvlCTduw2aHLVB62NvCiZUlALLqBe5v684Aw=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "d2332963662edffacfddfad59ff4f709dde80ffe",
"rev": "e9f06adb793d1cca5384907b3b8a4071d5d7cb19",
"type": "github"
},
"original": {
@ -1199,17 +1176,16 @@
},
"nixvim": {
"inputs": {
"beautysh": "beautysh",
"flake-utils": "flake-utils_4",
"nixpkgs": "nixpkgs_5",
"pre-commit-hooks": "pre-commit-hooks"
},
"locked": {
"lastModified": 1701379698,
"narHash": "sha256-u4wV7iI5XCMkj/BSyr9sih9WgevnYhw01nFWAerFEGE=",
"lastModified": 1701879058,
"narHash": "sha256-cOHIndHbXJ69DeYpa3srPBmAa+MuJhq1RgF1J1I3c3s=",
"owner": "pta2002",
"repo": "nixvim",
"rev": "28fc85484ab827912b1785484dd709c62d9a8237",
"rev": "032f697da6ae830460095f881644da650f17a967",
"type": "github"
},
"original": {
@ -1220,11 +1196,11 @@
},
"nur": {
"locked": {
"lastModified": 1701525157,
"narHash": "sha256-GVE2K1UcVRBOghRWmgpIwKjziwfmqSMMLYzec8CHCzA=",
"lastModified": 1701887101,
"narHash": "sha256-noDEwz+/eMQ3wdVML9XJOu9MiN40IoDDMOvsqSi83Pk=",
"owner": "nix-community",
"repo": "NUR",
"rev": "2852283c5f07fdb12fa595d0d2d5fa27d8557586",
"rev": "d2163cf91fb3fd644539aeddd9ca8af12ac97e70",
"type": "github"
},
"original": {
@ -1234,33 +1210,6 @@
}
},
"poetry2nix": {
"inputs": {
"flake-utils": [
"nixvim",
"beautysh",
"utils"
],
"nixpkgs": [
"nixvim",
"beautysh",
"nixpkgs"
]
},
"locked": {
"lastModified": 1658665240,
"narHash": "sha256-/wkx7D7enyBPRjIkK0w7QxLQhzEkb3UxNQnjyc3FTUI=",
"owner": "nix-community",
"repo": "poetry2nix",
"rev": "8b8edc85d24661d5a6d0d71d6a7011f3e699780f",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "poetry2nix",
"type": "github"
}
},
"poetry2nix_2": {
"flake": false,
"locked": {
"lastModified": 1666918719,
@ -1626,21 +1575,6 @@
}
},
"utils_3": {
"locked": {
"lastModified": 1678901627,
"narHash": "sha256-U02riOqrKKzwjsxc/400XnElV+UtPUQWpANPlyazjH0=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "93a2b84fc4b70d9e089d029deacc3583435c2ed6",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"utils_4": {
"inputs": {
"systems": "systems_5"
},
@ -1664,7 +1598,7 @@
"flake-utils": "flake-utils_6",
"nix": "nix",
"nixpkgs": "nixpkgs_8",
"utils": "utils_4"
"utils": "utils_3"
},
"locked": {
"lastModified": 1699433213,

View File

@ -1,6 +1,16 @@
{ config, pkgs, lib, ... }:
with lib;
let cfg = config.programs.v.nvim;
let
cfg = config.programs.v.nvim;
cmp-vimtex = pkgs.vimUtils.buildVimPlugin {
name = "cmp-vimtex";
src = pkgs.fetchFromGitHub {
owner = "micangl";
repo = "cmp-vimtex";
rev = "2b5089a79b29418e6afcdc7804d2b9f2f002946b";
hash = "sha256-IcXjCNXfiV8WMP4S41uy3C9OsKUi3zJnvg5MJVu3Khw=";
};
};
in {
options.programs.v.nvim = { enable = mkEnableOption "nvim"; };
config = mkIf cfg.enable {
@ -8,11 +18,14 @@ in {
enable = true;
package = pkgs.neovim-unwrapped;
vimAlias = true;
luaLoader.enable = true;
globals.mapleader = " ";
options.number = true;
clipboard = { providers.wl-copy.enable = true; };
keymaps = [
{
mode = "n";
@ -32,6 +45,16 @@ in {
action = "require('Comment.api').toggle.linewise.current";
lua = true;
}
{
mode = "x";
key = "<C-_>";
action = ''
function()
require('Comment.api').toggle.linewise(vim.fn.visualmode())
end
'';
lua = true;
}
{
mode = "n";
key = "g=";
@ -40,32 +63,31 @@ in {
}
];
# keymaps = [
# {
# key = "<leader>ff";
# mode = "n";
# lua = true;
# action = "require('telescope.builtin').find_files()";
# }
# {
# key = "<leader>fg";
# mode = "n";
# lua = true;
# action = "require('Comment.api').toggle.linewise.current()<cr>";
# }
# {
# key = "g=";
# mode = "n";
# lua = true;
# action = "vim.lsp.buf.format{async=true}<cr>";
# }
# ];
extraPlugins = with pkgs.vimPlugins; [
FixCursorHold-nvim
cmp-vimtex
luasnip
plenary-nvim
neotest
neotest-plenary
neotest-rust
];
extraPlugins = with pkgs.vimPlugins; [ catppuccin-nvim luasnip ];
colorschemes.catppuccin = {
enable = true;
flavour = "frappe";
};
colorscheme = "catppuccin-frappe";
extraConfigLua = "";
extraConfigLua = ''
require("neotest").setup({
adapters = {
require("neotest-plenary"),
require("neotest-rust") {
args = { "--no-capture" },
}
},
})
'';
plugins = {
bufferline.enable = true;
@ -86,7 +108,7 @@ in {
treesitter = {
enable = true;
nixGrammars = true;
# ensureInstalled = [ ];
disabledLanguages = [ "latex" ];
};
surround.enable = true;
fugitive.enable = true;
@ -105,7 +127,10 @@ in {
enable = true;
servers = {
nil_ls.enable = true;
rust-analyzer.enable = true;
rust-analyzer = {
installCargo = false;
installRustc = false;
};
pyright.enable = true;
elixirls.enable = true;
clangd.enable = true;
@ -114,12 +139,18 @@ in {
};
trouble.enable = true;
lspkind.enable = true;
vimtex.enable = true;
nvim-cmp = {
enable = true;
autoEnableSources = true;
sources = [
{ name = "nvim_lsp"; }
{ name = "cmp-latex-symbols"; }
{
name = "vimtex";
}
# { name = "cmp-latex-symbols"; }
{
name = "luasnip";
option = { show_autosnippets = true; };

View File

@ -5,7 +5,7 @@ in {
options.programs.v.rust = { enable = mkEnableOption "rust"; };
config = mkIf cfg.enable {
home = {
packages = with pkgs; [ rustup ];
packages = with pkgs; [ rustup cargo-nextest cargo-msrv ];
file = {
".cargo/config.toml".text = ''