about summary refs log tree commit diff
path: root/pkgs/by-name
diff options
context:
space:
mode:
authorBen Darwin2024-07-24 17:50:43 -0400
committerBen Darwin2024-07-24 17:55:01 -0400
commita21dedffd03f99c2b0a1d91b814347c2c68c70d3 (patch)
tree7ff35cdb44530cd75b0e614a976d9ec3216eee27 /pkgs/by-name
parent48eb49d9490d06b010c1fe9fc6bc2406badf9588 (diff)
fastapi-cli: refactor to use python3Packages.fastapi-cli
Previously there were essentially two copies of the same expression in tree.
Diffstat (limited to 'pkgs/by-name')
-rw-r--r--pkgs/by-name/fa/fastapi-cli/package.nix44
1 files changed, 3 insertions, 41 deletions
diff --git a/pkgs/by-name/fa/fastapi-cli/package.nix b/pkgs/by-name/fa/fastapi-cli/package.nix
index f940531aa46c..0c274ad6f138 100644
--- a/pkgs/by-name/fa/fastapi-cli/package.nix
+++ b/pkgs/by-name/fa/fastapi-cli/package.nix
@@ -1,42 +1,4 @@
-{
-  lib,
-  python3,
-  fetchFromGitHub,
-}:
+{ python3 }:
 
-python3.pkgs.buildPythonApplication rec {
-  pname = "fastapi-cli";
-  version = "0.0.4";
-  pyproject = true;
-
-  src = fetchFromGitHub {
-    owner = "tiangolo";
-    repo = "fastapi-cli";
-    rev = "refs/tags/${version}";
-    hash = "sha256-eWvZn7ZeLnQZAvGOzY77o6oO5y+QV2cx+peBov9YpJE=";
-  };
-
-  build-system = [ python3.pkgs.pdm-backend ];
-
-  dependencies = with python3.pkgs; [
-    rich
-    typer
-  ];
-
-  optional-dependencies = with python3.pkgs; {
-    standard = [
-      fastapi
-      uvicorn
-    ];
-  };
-
-  pythonImportsCheck = [ "fastapi_cli" ];
-
-  meta = {
-    description = "Run and manage FastAPI apps from the command line with FastAPI CLI";
-    homepage = "https://github.com/tiangolo/fastapi-cli";
-    license = lib.licenses.mit;
-    maintainers = with lib.maintainers; [ drupol ];
-    mainProgram = "fastapi-cli";
-  };
-}
+with python3.pkgs;
+toPythonApplication fastapi-cli