set stateVersion in toplevel

This commit is contained in:
Ivan Kirilov Dimitrov 2024-07-05 13:29:07 +02:00
parent c3887fdf8b
commit a29de4f7ca
No known key found for this signature in database
GPG Key ID: 0BDAD4B211C49294
3 changed files with 6 additions and 5 deletions

View File

@ -1,6 +1,7 @@
top@{ inputs, ... }: { top@{ inputs, ... }: {
imports = [ ./nixos ./home ]; imports = [ ./nixos ./home ];
systems = [ "x86_64-linux" ]; systems = [ "x86_64-linux" ];
flake.stateVersion = "24.05";
perSystem = perSystem@{ system, ... }: { perSystem = perSystem@{ system, ... }: {
config._module.args = { config._module.args = {
pkgs = import inputs.nixpkgs { pkgs = import inputs.nixpkgs {

View File

@ -1,15 +1,15 @@
toplevel@{ inputs, withSystem, ... }: toplevel@{ inputs, withSystem, config, ... }:
{ {
flake.homeConfigurations.ivand = withSystem "x86_64-linux" (ctx@{ pkgs, ... }: flake.homeConfigurations.ivand = withSystem "x86_64-linux" (ctx@{ pkgs, ... }:
inputs.home-manager.lib.homeManagerConfiguration { inputs.home-manager.lib.homeManagerConfiguration {
inherit pkgs; inherit pkgs;
modules = modules =
let let
mods = toplevel.config.flake.homeManagerModules; mods = config.flake.homeManagerModules;
in in
[ [
{ {
home.stateVersion = "24.05"; home.stateVersion = config.flake.stateVersion;
} }
inputs.nid.hmModules.nix-index inputs.nid.hmModules.nix-index
inputs.catppuccin.homeManagerModules.catppuccin inputs.catppuccin.homeManagerModules.catppuccin

View File

@ -1,4 +1,4 @@
{ moduleWithSystem, ... }: { top@{ moduleWithSystem, ... }: {
flake.nixosModules = { flake.nixosModules = {
grub = { grub = {
boot = { boot = {
@ -16,7 +16,7 @@
}; };
}; };
base = moduleWithSystem (toplevel@{ ... }: perSystem@{ pkgs, ... }: { base = moduleWithSystem (toplevel@{ ... }: perSystem@{ pkgs, ... }: {
system.stateVersion = "24.05"; system.stateVersion = top.config.flake.stateVersion;
nix = { nix = {
extraOptions = '' extraOptions = ''
experimental-features = nix-command flakes experimental-features = nix-command flakes