Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at gcc-offload 79 lines 1.5 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 pythonOlder, 6 7 # build-system 8 poetry-core, 9 10 # dependencies 11 django, 12 13 # optionals 14 bleach, 15 docutils, 16 markdown, 17 pygments, 18 python-creole, 19 smartypants, 20 textile, 21 22 # tests 23 pytest-django, 24 pytestCheckHook, 25}: 26 27buildPythonPackage rec { 28 pname = "django-markup"; 29 version = "1.9.1"; 30 pyproject = true; 31 32 disabled = pythonOlder "3.8"; 33 34 src = fetchFromGitHub { 35 owner = "bartTC"; 36 repo = "django-markup"; 37 rev = "refs/tags/v${version}"; 38 hash = "sha256-dj5Z36W4Stly203SKWpR/DF+Wf7+ejbZnDCmHNRb3c0="; 39 }; 40 41 postPatch = '' 42 sed -i "/--cov/d" pyproject.toml 43 ''; 44 45 build-system = [ poetry-core ]; 46 47 dependencies = [ django ]; 48 49 optional-dependencies = { 50 all_filter_dependencies = [ 51 bleach 52 docutils 53 markdown 54 pygments 55 python-creole 56 smartypants 57 textile 58 ]; 59 }; 60 61 pythonImportsCheck = [ "django_markup" ]; 62 63 nativeCheckInputs = [ 64 pytest-django 65 pytestCheckHook 66 ] ++ optional-dependencies.all_filter_dependencies; 67 68 preCheck = '' 69 export DJANGO_SETTINGS_MODULE=django_markup.tests 70 ''; 71 72 meta = with lib; { 73 description = "Generic Django application to convert text with specific markup to html"; 74 homepage = "https://github.com/bartTC/django-markup"; 75 changelog = "https://github.com/bartTC/django-markup/blob/v${version}/CHANGELOG.md"; 76 license = licenses.mit; 77 maintainers = with maintainers; [ hexa ]; 78 }; 79}