2021-02-05 17:12:51 +00:00
|
|
|
{ lib, stdenv
|
2022-06-26 10:26:21 +00:00
|
|
|
, buildPythonPackage
|
2020-12-27 14:24:52 +00:00
|
|
|
, fetchPypi
|
|
|
|
, isPy3k
|
|
|
|
, cli-helpers
|
|
|
|
, click
|
|
|
|
, configobj
|
2021-08-05 21:33:18 +00:00
|
|
|
, prompt-toolkit
|
2020-12-27 14:24:52 +00:00
|
|
|
, psycopg2
|
|
|
|
, pygments
|
|
|
|
, sqlparse
|
|
|
|
, pgspecial
|
|
|
|
, setproctitle
|
|
|
|
, keyring
|
|
|
|
, pendulum
|
|
|
|
, pytestCheckHook
|
2022-04-15 01:41:22 +00:00
|
|
|
, sshtunnel
|
2020-12-27 14:24:52 +00:00
|
|
|
, mock
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
2022-06-26 10:26:21 +00:00
|
|
|
# this is a pythonPackage because of the ipython line magics in pgcli.magic
|
|
|
|
# integrating with ipython-sql
|
|
|
|
buildPythonPackage rec {
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "pgcli";
|
2022-04-15 01:41:22 +00:00
|
|
|
version = "3.4.1";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2022-04-15 01:41:22 +00:00
|
|
|
sha256 = "sha256-8DkwGH4n1g32WMqKBPtgHsXXR2xzXysVQsat7Fysj+I=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
2020-12-27 14:24:52 +00:00
|
|
|
cli-helpers
|
|
|
|
click
|
|
|
|
configobj
|
2021-08-05 21:33:18 +00:00
|
|
|
prompt-toolkit
|
2020-12-27 14:24:52 +00:00
|
|
|
psycopg2
|
|
|
|
pygments
|
|
|
|
sqlparse
|
|
|
|
pgspecial
|
|
|
|
setproctitle
|
|
|
|
keyring
|
|
|
|
pendulum
|
2022-04-15 01:41:22 +00:00
|
|
|
sshtunnel
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
2020-12-27 14:24:52 +00:00
|
|
|
checkInputs = [ pytestCheckHook mock ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-01-19 23:45:15 +00:00
|
|
|
disabledTests = lib.optionals stdenv.isDarwin [ "test_application_name_db_uri" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Command-line interface for PostgreSQL";
|
|
|
|
longDescription = ''
|
|
|
|
Rich command-line interface for PostgreSQL with auto-completion and
|
|
|
|
syntax highlighting.
|
|
|
|
'';
|
|
|
|
homepage = "https://pgcli.com";
|
2021-09-18 10:52:07 +00:00
|
|
|
changelog = "https://github.com/dbcli/pgcli/raw/v${version}/changelog.rst";
|
2020-04-24 23:36:52 +00:00
|
|
|
license = licenses.bsd3;
|
|
|
|
maintainers = with maintainers; [ dywedir ];
|
|
|
|
};
|
|
|
|
}
|