1{ stdenv, buildPythonPackage, fetchPypi, substituteAll, locale, pytest }: 2 3buildPythonPackage rec { 4 pname = "click"; 5 version = "6.7"; 6 7 src = fetchPypi { 8 inherit pname version; 9 sha256 = "02qkfpykbq35id8glfgwc38yc430427yd05z1wc5cnld8zgicmgi"; 10 }; 11 12 patches = stdenv.lib.optional (stdenv.lib.versionAtLeast version "6.7") (substituteAll { 13 src = ./fix-paths.patch; 14 locale = "${locale}/bin/locale"; 15 }); 16 17 buildInputs = [ pytest ]; 18 19 checkPhase = '' 20 py.test tests 21 ''; 22 23 # https://github.com/pallets/click/issues/823 24 doCheck = false; 25 26 meta = with stdenv.lib; { 27 homepage = http://click.pocoo.org/; 28 description = "Create beautiful command line interfaces in Python"; 29 longDescription = '' 30 A Python package for creating beautiful command line interfaces in a 31 composable way, with as little code as necessary. 32 ''; 33 license = licenses.bsd3; 34 }; 35}