1{
2 lib,
3 python3Packages,
4 fetchFromGitHub,
5 versionCheckHook,
6}:
7
8python3Packages.buildPythonApplication rec {
9 pname = "cli50";
10 version = "8.0.1";
11 pyproject = true;
12
13 src = fetchFromGitHub {
14 owner = "cs50";
15 repo = "cli50";
16 tag = "v${version}";
17 hash = "sha256-0gu31NPql8pFPN4jFbPwYkQmF/rbrAai6EY1ZVfXLew=";
18 };
19
20 build-system = [
21 python3Packages.setuptools
22 ];
23
24 dependencies = with python3Packages; [
25 inflect
26 packaging
27 requests
28 tzlocal
29 ];
30
31 pythonImportsCheck = [ "cli50" ];
32
33 nativeCheckInputs = [ versionCheckHook ];
34 versionCheckProgramArg = "--version";
35
36 # no python tests
37
38 meta = {
39 description = "Mount directories into cs50/cli containers";
40 homepage = "https://cs50.readthedocs.io/cli50/";
41 downloadPage = "https://github.com/cs50/cli50";
42 changelog = "https://github.com/cs50/cli50/releases/tag/v${version}";
43 license = lib.licenses.gpl3Only;
44 platforms = lib.platforms.unix;
45 maintainers = with lib.maintainers; [ ethancedwards8 ];
46 mainProgram = "cli50";
47 };
48}