From 353f7b0cc53778f1a6956d6b60f362369b7cf932 Mon Sep 17 00:00:00 2001 From: Gaetan Lepage Date: Thu, 17 Apr 2025 17:06:42 +0200 Subject: [PATCH] oterm: 0.9.3 -> 0.11.1 Diff: https://github.com/ggozad/oterm/compare/refs/tags/0.9.3...refs/tags/0.11.1 Changelog: https://github.com/ggozad/oterm/releases/tag/0.11.1 --- pkgs/by-name/ot/oterm/package.nix | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) diff --git a/pkgs/by-name/ot/oterm/package.nix b/pkgs/by-name/ot/oterm/package.nix index f9e678ccc439..b6dd44bef0fd 100644 --- a/pkgs/by-name/ot/oterm/package.nix +++ b/pkgs/by-name/ot/oterm/package.nix @@ -1,19 +1,22 @@ { lib, + stdenv, python3Packages, fetchFromGitHub, + versionCheckHook, + nix-update-script, }: python3Packages.buildPythonApplication rec { pname = "oterm"; - version = "0.9.3"; + version = "0.11.1"; pyproject = true; src = fetchFromGitHub { owner = "ggozad"; repo = "oterm"; tag = version; - hash = "sha256-2zzDVUZc+H2tBO5scRUjwz859uaQIbpvCaC0bm4B7NM="; + hash = "sha256-b/+siNzmM6RUJ3jv/2dNJJFueejChKde0D5r8J0lTqM="; }; pythonRelaxDeps = [ @@ -23,6 +26,7 @@ python3Packages.buildPythonApplication rec { "ollama" "packaging" "pillow" + "pydantic" "textual" "typer" ]; @@ -43,14 +47,24 @@ python3Packages.buildPythonApplication rec { python-dotenv rich-pixels textual + textual-image textualeffects typer ]; pythonImportsCheck = [ "oterm" ]; - # Tests require a HTTP connection to ollama - doCheck = false; + # Python tests require a HTTP connection to ollama + + # Fails on darwin with: PermissionError: [Errno 1] Operation not permitted: '/var/empty/Library' + nativeCheckInputs = lib.optionals (!stdenv.hostPlatform.isDarwin) [ + versionCheckHook + ]; + versionCheckProgramArg = "--version"; + + passthru = { + updateScript = nix-update-script { }; + }; meta = { description = "Text-based terminal client for Ollama";