mirror of
https://github.com/nix-community/home-manager
synced 2025-01-11 03:29:50 +01:00
xresources: allow floating point values
This commit is contained in:
parent
cb27edb522
commit
1f74238a4c
3 changed files with 3 additions and 1 deletions
|
@ -32,7 +32,7 @@ in {
|
||||||
xresources.properties = mkOption {
|
xresources.properties = mkOption {
|
||||||
type = with types;
|
type = with types;
|
||||||
let
|
let
|
||||||
prim = either bool (either int str);
|
prim = oneOf [ bool int float str ];
|
||||||
entry = either prim (listOf prim);
|
entry = either prim (listOf prim);
|
||||||
in nullOr (attrsOf entry);
|
in nullOr (attrsOf entry);
|
||||||
default = null;
|
default = null;
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
Test*boolean1: true
|
Test*boolean1: true
|
||||||
Test*boolean2: false
|
Test*boolean2: false
|
||||||
|
Test*float: 12.300000
|
||||||
Test*int: 10
|
Test*int: 10
|
||||||
Test*list: list-str, true, false, 10
|
Test*list: list-str, true, false, 10
|
||||||
Test*string: test-string
|
Test*string: test-string
|
||||||
|
|
|
@ -7,6 +7,7 @@
|
||||||
"Test*boolean1" = true;
|
"Test*boolean1" = true;
|
||||||
"Test*boolean2" = false;
|
"Test*boolean2" = false;
|
||||||
"Test*int" = 10;
|
"Test*int" = 10;
|
||||||
|
"Test*float" = 12.3;
|
||||||
"Test*list" = [ "list-str" true false 10 ];
|
"Test*list" = [ "list-str" true false 10 ];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue