[fix] nvim: system module brok plugins
Some checks failed
/ build (docs) (push) Successful in 3s
/ build (nvim) (push) Has been cancelled
/ build (nixosConfigurations.vm.config.system.build.toplevel) (push) Has been cancelled
/ check (push) Has been cancelled

The architecture of nixvim doesn't let me use NixOS modules T-T, I need
to use manual imports instead.
This commit is contained in:
Jalil David Salamé Messina 2024-06-22 19:25:51 +02:00
parent ac5e62a37c
commit 88fe396bf2
Signed by: jalil
GPG key ID: F016B9E770737A0B
6 changed files with 480 additions and 489 deletions

View file

@ -250,8 +250,8 @@
system,
}: {
default = pkgs.mkShell {
buildInputs = with pkgs; [
just
buildInputs = [
pkgs.just
self.packages.${system}.nvim
];
QEMU_OPTS_WL = "--enable-kvm -smp 4 -device virtio-gpu-rutabaga,gfxstream-vulkan=on,cross-domain=on,hostmem=2G,wsi=headless";

View file

@ -1,13 +1,6 @@
{
lib,
config,
helpers,
...
}: let
{helpers, ...}: let
inherit (helpers) mkRaw;
cfg = config.jhome.nvim;
in
lib.mkIf cfg.enable {
in {
autoGroups = {
"highlightOnYank" = {};
"lspConfig" = {};

View file

@ -1,5 +1,14 @@
{pkgs, ...} @ opts: {
{
lib,
pkgs,
config,
helpers,
...
}: let
# Force inputs to be included
nixvim = import ./nixvim.nix {inherit lib pkgs config helpers;};
in {
imports = [./options.nix];
config.programs.nixvim = (import ./nixvim.nix opts).config;
config.programs.nixvim = nixvim.config;
}

View file

@ -1,15 +1,6 @@
{
lib,
config,
helpers,
...
}: let
{helpers, ...}: let
inherit (helpers) mkRaw;
cfg = config.jhome.nvim;
in
lib.mkIf cfg.enable {
keymaps = [
in [
# Quickfix
{
mode = "n";
@ -154,5 +145,4 @@ in
action = mkRaw "require('nvim-silicon').clip";
options.desc = "Snap Code (to clipboard)";
}
];
}
]

View file

@ -10,14 +10,18 @@
darwinAvailable = args ? darwinConfig;
canSetAsDefault = hmAvailable || nixosAvailable;
notStandalone = hmAvailable || nixosAvailable || darwinAvailable;
augroups = import ./augroups.nix args;
in {
imports = [./options.nix ./plugins.nix ./mappings.nix ./augroups.nix];
imports = [./options.nix];
config = lib.mkMerge [
(lib.optionalAttrs canSetAsDefault {defaultEditor = lib.mkDefault true;})
(lib.optionalAttrs notStandalone {enable = lib.mkDefault true;})
(lib.mkIf cfg.enable {
package = pkgs.unstable.neovim-unwrapped;
inherit (augroups) autoGroups autoCmd;
plugins = import ./plugins.nix args;
keymaps = import ./mappings.nix args;
globals.mapleader = " ";
# Appearance
colorschemes.gruvbox = {

View file

@ -2,14 +2,10 @@
lib,
pkgs,
helpers,
config,
...
}: let
inherit (helpers) mkRaw;
cfg = config.jhome.nvim;
in
lib.mkIf cfg.enable {
plugins = {
in {
bacon = {
enable = true;
settings.quickfix.enabled = true;
@ -243,5 +239,4 @@ in
enable = true;
settings.auto_close = true;
};
};
}