nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 lib,
3 buildPythonPackage,
4 fetchPypi,
5 configobj,
6 mock,
7 pytestCheckHook,
8 pygments,
9 tabulate,
10}:
11
12buildPythonPackage rec {
13 pname = "cli-helpers";
14 version = "2.9.0";
15 format = "setuptools";
16
17 src = fetchPypi {
18 pname = "cli_helpers";
19 inherit version;
20 hash = "sha256-qYh0XsQx3a5wf3ON0NE4kLdKAKKqBCjqzX/B4Dsgahc=";
21 };
22
23 propagatedBuildInputs = [
24 configobj
25 tabulate
26 ]
27 ++ tabulate.optional-dependencies.widechars;
28
29 optional-dependencies = {
30 styles = [ pygments ];
31 };
32
33 nativeCheckInputs = [
34 pytestCheckHook
35 mock
36 ]
37 ++ lib.concatAttrValues optional-dependencies;
38
39 meta = {
40 description = "Python helpers for common CLI tasks";
41 longDescription = ''
42 CLI Helpers is a Python package that makes it easy to perform common
43 tasks when building command-line apps. It's a helper library for
44 command-line interfaces.
45
46 Libraries like Click and Python Prompt Toolkit are amazing tools that
47 help you create quality apps. CLI Helpers complements these libraries by
48 wrapping up common tasks in simple interfaces.
49
50 CLI Helpers is not focused on your app's design pattern or framework --
51 you can use it on its own or in combination with other libraries. It's
52 lightweight and easy to extend.
53
54 What's included in CLI Helpers?
55
56 - Prettyprinting of tabular data with custom pre-processing
57 - [in progress] config file reading/writing
58
59 Read the documentation at http://cli-helpers.rtfd.io
60 '';
61 homepage = "https://cli-helpers.readthedocs.io/en/stable/";
62 license = lib.licenses.bsd3;
63 maintainers = [ lib.maintainers.kalbasit ];
64 };
65}