567e8dfd8e
This commit was created by a combination of scripts and tools: - an ast-grep script to prefix things in meta with `lib.`, - a modified nixf-diagnose / nixf combination to remove unused `with lib;`, and - regular nixfmt. Co-authored-by: Wolfgang Walther <walther@technowledgy.de>
39 lines
729 B
Nix
39 lines
729 B
Nix
{
|
|
lib,
|
|
buildPythonPackage,
|
|
fetchFromGitHub,
|
|
pytest,
|
|
pythonOlder,
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "mutf8";
|
|
version = "1.0.6";
|
|
format = "setuptools";
|
|
|
|
disabled = pythonOlder "3.6";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "TkTech";
|
|
repo = "mutf8";
|
|
rev = "v${version}";
|
|
hash = "sha256-4Ojn3t0EbOVdrYEiY8JegJuvW9sz8jt9tKFwOluiGQo=";
|
|
};
|
|
|
|
nativeCheckInputs = [ pytest ];
|
|
|
|
checkPhase = ''
|
|
# Using pytestCheckHook results in test failures
|
|
pytest
|
|
'';
|
|
|
|
pythonImportsCheck = [ "mutf8" ];
|
|
|
|
meta = {
|
|
description = "Fast MUTF-8 encoder & decoder";
|
|
homepage = "https://github.com/TkTech/mutf8";
|
|
license = lib.licenses.mit;
|
|
maintainers = with lib.maintainers; [ fab ];
|
|
};
|
|
}
|