nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at r-updates 76 lines 2.0 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 docopt, 5 fetchFromGitHub, 6 flit-core, 7 hypothesis, 8 inform, 9 nestedtext, 10 pytestCheckHook, 11 quantiphy, 12 voluptuous, 13}: 14 15buildPythonPackage (finalAttrs: { 16 pname = "nestedtext"; 17 version = "3.8"; 18 pyproject = true; 19 20 src = fetchFromGitHub { 21 owner = "KenKundert"; 22 repo = "nestedtext"; 23 tag = "v${finalAttrs.version}"; 24 hash = "sha256-eg5Q11dl9ikGpNYx2Sd47MBPC9S4W2M6PpehFpowzdk="; 25 }; 26 27 build-system = [ flit-core ]; 28 29 dependencies = [ inform ]; 30 31 nativeCheckInputs = [ 32 docopt 33 hypothesis 34 quantiphy 35 pytestCheckHook 36 voluptuous 37 ]; 38 39 # Tests depend on quantiphy. To avoid infinite recursion, tests are only 40 # enabled when building passthru.tests. 41 doCheck = false; 42 43 disabledTestPaths = [ 44 # Avoids an ImportMismatchError. 45 "build" 46 # Examples are prefixed with test_ 47 "examples/" 48 ]; 49 50 passthru.tests = { 51 runTests = nestedtext.overrideAttrs (_: { 52 doCheck = true; 53 }); 54 }; 55 56 pythonImportsCheck = [ "nestedtext" ]; 57 58 meta = { 59 description = "Human friendly data format"; 60 longDescription = '' 61 NestedText is a file format for holding data that is to be entered, 62 edited, or viewed by people. It allows data to be organized into a nested 63 collection of dictionaries, lists, and strings. In this way it is similar 64 to JSON, YAML and TOML, but without the complexity and risk of YAML and 65 without the syntactic clutter of JSON and TOML. NestedText is both simple 66 and natural. Only a small number of concepts and rules must be kept in 67 mind when creating it. It is easily created, modified, or viewed with a 68 text editor and easily understood and used by both programmers and 69 non-programmers. 70 ''; 71 homepage = "https://nestedtext.org"; 72 changelog = "https://github.com/KenKundert/nestedtext/blob/${finalAttrs.src.tag}/doc/releases.rst"; 73 license = lib.licenses.mit; 74 maintainers = with lib.maintainers; [ jeremyschlatter ]; 75 }; 76})