mirror of
https://github.com/nix-community/nix-on-droid.git
synced 2025-11-08 11:36:07 +01:00
Add assertion for needed upgrade to nixpkgs 20.03
This commit is contained in:
parent
b4c185c146
commit
e260c20a2e
1 changed files with 9 additions and 2 deletions
|
|
@ -8,7 +8,9 @@ let
|
|||
cfg = config.home-manager;
|
||||
|
||||
tryEval = builtins.tryEval <home-manager/modules/modules.nix>;
|
||||
assertion = tryEval.success && builtins.functionArgs (import tryEval.value) ? useNixpkgsModule;
|
||||
assertionNixpkgs = types ? submoduleWith;
|
||||
assertionHomeManager = tryEval.success && builtins.functionArgs (import tryEval.value) ? useNixpkgsModule;
|
||||
assertion = assertionNixpkgs && assertionHomeManager;
|
||||
|
||||
extendedLib = import <home-manager/modules/lib/stdlib-extended.nix> pkgs.lib;
|
||||
|
||||
|
|
@ -82,7 +84,12 @@ in
|
|||
{
|
||||
assertions = [
|
||||
{
|
||||
inherit assertion;
|
||||
assertion = assertionNixpkgs;
|
||||
message = "You are currently using release-19.09 branch of nixpkgs, you need "
|
||||
+ "to update to the release-20.03 channel.";
|
||||
}
|
||||
{
|
||||
assertion = assertionHomeManager;
|
||||
message = "You are currently using release-19.09 branch of home-manager, you need "
|
||||
+ "to update to the release-20.03 channel.";
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue