Is anybody needs floats in options :-)

  isFloat = x: isInt x ||
      ( isString x &&
        3 > length (splitString "." x) &&
        all (s: 2 == length (splitString s " 0123456789. "))
(stringToCharacters x)
      );

  float = mkOptionType {
    name = "float";
    check = isFloat;
  };
_______________________________________________
nix-dev mailing list
[email protected]
http://lists.science.uu.nl/mailman/listinfo/nix-dev

Reply via email to