mirror of
https://github.com/nix-community/dream2nix.git
synced 2024-12-19 04:21:52 +03:00
fixup! Add schema validation for specific subsystems
This commit is contained in:
parent
45101cccc4
commit
e928819208
@ -7,7 +7,7 @@
|
|||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
"nodejsVersion": {
|
"nodejsVersion": {
|
||||||
"type": "integer"
|
"type": "string"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"_subsystem": {
|
"_subsystem": {
|
||||||
"nodejsVersion": 14
|
"nodejsVersion": "14"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -44,9 +44,9 @@
|
|||||||
|
|
||||||
nodejs =
|
nodejs =
|
||||||
if args ? nodejs
|
if args ? nodejs
|
||||||
then args.nodejs
|
then b.toString args.nodejs
|
||||||
else
|
else
|
||||||
pkgs."nodejs-${builtins.toString nodejsVersion}_x"
|
pkgs."nodejs-${nodejsVersion}_x"
|
||||||
or (throw "Could not find nodejs version '${nodejsVersion}' in pkgs");
|
or (throw "Could not find nodejs version '${nodejsVersion}' in pkgs");
|
||||||
|
|
||||||
nodeSources = runCommandLocal "node-sources" {} ''
|
nodeSources = runCommandLocal "node-sources" {} ''
|
||||||
|
@ -170,7 +170,7 @@
|
|||||||
|
|
||||||
subsystemName = "nodejs";
|
subsystemName = "nodejs";
|
||||||
|
|
||||||
subsystemAttrs = {nodejsVersion = args.nodejs;};
|
subsystemAttrs = {nodejsVersion = b.toString args.nodejs;};
|
||||||
|
|
||||||
# functions
|
# functions
|
||||||
serializePackages = inputData: let
|
serializePackages = inputData: let
|
||||||
|
@ -140,7 +140,7 @@
|
|||||||
|
|
||||||
subsystemName = "nodejs";
|
subsystemName = "nodejs";
|
||||||
|
|
||||||
subsystemAttrs = {nodejsVersion = args.nodejs;};
|
subsystemAttrs = {nodejsVersion = b.toString args.nodejs;};
|
||||||
|
|
||||||
keys = {
|
keys = {
|
||||||
yarnName = rawObj: finalObj:
|
yarnName = rawObj: finalObj:
|
||||||
|
Loading…
Reference in New Issue
Block a user