mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-10-30 16:10:36 +00:00
36 lines
928 B
Nix
36 lines
928 B
Nix
{
|
|
lib,
|
|
buildPythonPackage,
|
|
fetchFromGitHub,
|
|
python,
|
|
}:
|
|
|
|
buildPythonPackage {
|
|
pname = "dlx";
|
|
version = "1.0.4";
|
|
format = "setuptools";
|
|
|
|
# untagged releases
|
|
src = fetchFromGitHub {
|
|
owner = "sraaphorst";
|
|
repo = "dlx_python";
|
|
rev = "02d1ed534df60513095633da07e67a6593b9e9b4";
|
|
hash = "sha256-E5bdXwybaahHdjEEIgemp7FRTwm34zSzN73y6xddzTA=";
|
|
};
|
|
|
|
# No test suite, so just run an example
|
|
pythonImportsCheck = [ "dlx" ];
|
|
# ./examples/design.py requires pyncomb, not in tree
|
|
checkPhase = ''
|
|
# example sudoku board from ./examples/sudoku.py
|
|
${python.interpreter} ./examples/sudoku.py 3 "070285010008903500000000000500010008010000090900040003000000000002408600090632080"
|
|
'';
|
|
|
|
meta = {
|
|
description = "Implementation of Donald Knuth's Dancing Links algorithm";
|
|
homepage = "https://github.com/sraaphorst/dlx_python";
|
|
license = lib.licenses.asl20;
|
|
maintainers = [ ];
|
|
};
|
|
}
|