Fix configuration issues #256

Merged
jalil merged 3 commits from push-mtvkqlnskqqq into main 2025-01-18 12:09:12 +01:00
4 changed files with 11 additions and 30 deletions
Showing only changes of commit 7963190ef1 - Show all commits

View file

@ -2,15 +2,10 @@
{ {
flake.nixosModules = flake.nixosModules =
let let
nvim-config = nvim-config = {
{ pkgs, ... }:
{
imports = [ imports = [
inputs.nixvim.homeManagerModules.nixvim inputs.nixvim.homeManagerModules.nixvim
(import ../nvim { ../nvim
inherit (inputs) unstable;
inherit (pkgs) system;
})
]; ];
}; };
homeManagerModuleSandalone = import ../home { homeManagerModuleSandalone = import ../home {

View file

@ -3,19 +3,15 @@
flake.overlays.nixvim = inputs.nixvim.overlays.default; flake.overlays.nixvim = inputs.nixvim.overlays.default;
perSystem = perSystem =
{ pkgs, system, ... }: { system, ... }:
let let
nixvimLib = inputs.nixvim.lib.${system}; nixvimLib = inputs.nixvim.lib.${system};
nixvim = inputs.nixvim.legacyPackages.${system}; nixvim = inputs.nixvim.legacyPackages.${system};
testNvimModule = nixvimLib.check.mkTestDerivationFromNixvimModule; testNvimModule = nixvimLib.check.mkTestDerivationFromNixvimModule;
nvimModule = extraConfig: { nvimModule = extraConfig: {
inherit pkgs; pkgs = inputs.unstable.legacyPackages.${system};
extraSpecialArgs = {
inherit (inputs) unstable;
inherit system;
};
module = { module = {
imports = [ (import ../nvim/standalone.nix { standalone = true; }) ]; imports = [ ../nvim/standalone.nix ];
config = extraConfig; config = extraConfig;
}; };
}; };

View file

@ -1,4 +1,3 @@
{ system, unstable }:
{ lib, config, ... }: { lib, config, ... }:
let let
cfg = config.jhome.nvim; cfg = config.jhome.nvim;
@ -7,9 +6,8 @@ in
imports = [ ./options.nix ]; imports = [ ./options.nix ];
config.programs.nixvim = lib.mkMerge [ config.programs.nixvim = lib.mkMerge [
(import ./standalone.nix { standalone = false; }) (import ./standalone.nix)
(lib.mkIf cfg.enable { (lib.mkIf cfg.enable {
nixpkgs = lib.mkForce { pkgs = import unstable { inherit system; }; };
enable = true; enable = true;
defaultEditor = lib.mkDefault true; defaultEditor = lib.mkDefault true;
jhome.nvim = cfg; jhome.nvim = cfg;

View file

@ -1,11 +1,4 @@
{ standalone }: { pkgs, ... }:
{
pkgs,
system,
unstable,
lib,
...
}:
{ {
imports = [ imports = [
./options.nix ./options.nix
@ -17,7 +10,6 @@
config = { config = {
withRuby = false; withRuby = false;
nixpkgs = lib.optionalAttrs standalone { pkgs = unstable.legacyPackages.${system}; };
globals.mapleader = " "; globals.mapleader = " ";
# Appearance # Appearance
colorschemes.gruvbox = { colorschemes.gruvbox = {