about summary refs log tree commit diff
diff options
context:
space:
mode:
authorDavid Morgan <djm_uk@protonmail.com>2023-04-05 12:49:17 +0100
committerDavid Morgan <djm_uk@protonmail.com>2023-04-05 12:49:17 +0100
commitb1242bc59c436f7e8edeb57396823d16153352bc (patch)
treeed1ed3613c4d4e2b45f9254d38fab8aceba95f5b
parent8332758415d0efe9e7583b52e94772817e49b55f (diff)
chatblade: init at 0.2.1
-rw-r--r--pkgs/applications/misc/chatblade/default.nix47
-rw-r--r--pkgs/top-level/all-packages.nix2
2 files changed, 49 insertions, 0 deletions
diff --git a/pkgs/applications/misc/chatblade/default.nix b/pkgs/applications/misc/chatblade/default.nix
new file mode 100644
index 0000000000000..aee760a31fa9e
--- /dev/null
+++ b/pkgs/applications/misc/chatblade/default.nix
@@ -0,0 +1,47 @@
+{ lib, python3Packages }:
+
+python3Packages.buildPythonApplication rec {
+  pname = "chatblade";
+  version = "0.2.1";
+  format = "setuptools";
+
+  src = python3Packages.fetchPypi {
+    inherit pname version;
+    sha256 = "sha256-1syZyqdv+0iyAOWDychv3bGnkHs9SCxsEotxQ+G1UPo=";
+  };
+
+  doCheck = false; # there are no tests
+
+  pythonImportsCheck = [ "chatblade" ];
+  propagatedBuildInputs = with python3Packages; [
+    aiohttp
+    aiosignal
+    async-timeout
+    attrs
+    certifi
+    charset-normalizer
+    frozenlist
+    idna
+    markdown-it-py
+    mdurl
+    multidict
+    openai
+    platformdirs
+    pygments
+    pyyaml
+    regex
+    requests
+    rich
+    tiktoken
+    tqdm
+    urllib3
+    yarl
+  ];
+
+  meta = with lib; {
+    homepage = "https://github.com/npiv/chatblade/";
+    description = "A CLI Swiss Army Knife for ChatGPT";
+    license = licenses.gpl3Only;
+    maintainers = with maintainers; [ deejayem ];
+  };
+}
diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix
index 1ed01fd1e6fe3..6eab9524a3075 100644
--- a/pkgs/top-level/all-packages.nix
+++ b/pkgs/top-level/all-packages.nix
@@ -6380,6 +6380,8 @@ with pkgs;
 
   changetower = callPackage ../tools/networking/changetower { };
 
+  chatblade = callPackage ../applications/misc/chatblade { };
+
   checkbashisms = callPackage ../development/tools/misc/checkbashisms { };
 
   checkmate = callPackage ../development/tools/checkmate { };