Changed syntax of getVersion
svn path=/nixpkgs/branches/stdenv-updates/; revision=9733
This commit is contained in:
parent
07091eed11
commit
ebc6bb79cd
|
@ -1,8 +1,7 @@
|
||||||
args:
|
args:
|
||||||
rec {
|
builtins.listToAttrs [
|
||||||
recurseForDerivations = true;
|
{ name = "recurseForDerivations"; value = true; }
|
||||||
default = v_0_14_6;
|
{ name = "0.14.6"; value = (import ./0.14.6.nix) args; }
|
||||||
v_0_14_6 = (import ./0.14.6.nix) args;
|
{ name = "0.15"; value = (import ./0.15.nix) args; }
|
||||||
v_0_15 = (import ./0.15.nix) args;
|
{ name = "0.16.x"; value = (import ./0.16.x.nix) args; }
|
||||||
v_0_16_x = (import ./0.16.x.nix) args;
|
]
|
||||||
}
|
|
||||||
|
|
|
@ -142,10 +142,10 @@ rec {
|
||||||
# pkgname = getVersion "name" pkgname_alts;
|
# pkgname = getVersion "name" pkgname_alts;
|
||||||
#
|
#
|
||||||
# user will be able to write in his configuration.nix something like
|
# user will be able to write in his configuration.nix something like
|
||||||
# environment = { versions = { name = v_0_2; }; }; and pkgname will be equal
|
# name = { version = "0.2"; }; and pkgname will be equal
|
||||||
# to pkgname_alts.v_0_2. Using alts.default by default.
|
# to getAttr pkgname_alts "0.2". Using alts.default by default.
|
||||||
getVersion = name: alts: builtins.getAttr
|
getVersion = name: alts: builtins.getAttr
|
||||||
(getConfig [ "environment" "versions" name ] "default") alts;
|
(getConfig [ name "version" ] "default") alts;
|
||||||
|
|
||||||
# The same, another syntax.
|
# The same, another syntax.
|
||||||
# Warning: syntax for configuration.nix changed too
|
# Warning: syntax for configuration.nix changed too
|
||||||
|
|
Loading…
Reference in a new issue