Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib 2, python3 3, fetchPypi 4, glibcLocales 5}: 6 7with python3.pkgs; 8 9buildPythonApplication rec { 10 pname = "mycli"; 11 version = "1.26.1"; 12 13 src = fetchPypi { 14 inherit pname version; 15 sha256 = "sha256-jAMDXJtFJtv6CwhZZU4pdKDndZKp6bJ/QPWo2q6DvrE="; 16 }; 17 18 propagatedBuildInputs = [ 19 cli-helpers 20 click 21 configobj 22 importlib-resources 23 paramiko 24 prompt-toolkit 25 pyaes 26 pycrypto 27 pygments 28 pymysql 29 pyperclip 30 sqlglot 31 sqlparse 32 ]; 33 34 nativeCheckInputs = [ pytestCheckHook glibcLocales ]; 35 36 preCheck = '' 37 export HOME=. 38 export LC_ALL="en_US.UTF-8" 39 ''; 40 41 disabledTestPaths = [ 42 "mycli/packages/paramiko_stub/__init__.py" 43 ]; 44 45 disabledTests = [ 46 # Note: test_auto_escaped_col_names is currently failing due to a bug upstream. 47 # TODO: re-enable this test once there is a fix upstream. See 48 # https://github.com/dbcli/mycli/issues/1103 for details. 49 "test_auto_escaped_col_names" 50 ]; 51 52 postPatch = '' 53 substituteInPlace setup.py \ 54 --replace "cryptography == 36.0.2" "cryptography" 55 ''; 56 57 meta = with lib; { 58 inherit version; 59 description = "Command-line interface for MySQL"; 60 longDescription = '' 61 Rich command-line interface for MySQL with auto-completion and 62 syntax highlighting. 63 ''; 64 homepage = "http://mycli.net"; 65 license = licenses.bsd3; 66 maintainers = with maintainers; [ jojosch ]; 67 }; 68}