From 3efd6fe92245c2b1b81e12d74ee736ef7f887805 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Thu, 11 Feb 2021 16:48:36 +0100 Subject: [PATCH] jrnl: 1.9.8 -> 2.7 --- pkgs/applications/misc/jrnl/default.nix | 50 +++++++++++++++++++------ pkgs/top-level/all-packages.nix | 2 +- 2 files changed, 39 insertions(+), 13 deletions(-) diff --git a/pkgs/applications/misc/jrnl/default.nix b/pkgs/applications/misc/jrnl/default.nix index 79f87612e49a..8d2cabb5b8b2 100644 --- a/pkgs/applications/misc/jrnl/default.nix +++ b/pkgs/applications/misc/jrnl/default.nix @@ -1,30 +1,56 @@ { lib -, python3 +, ansiwrap +, asteval +, buildPythonApplication +, colorama +, cryptography +, fetchFromGitHub +, keyring +, parsedatetime +, poetry +, pytestCheckHook +, python-dateutil +, pytz +, pyxdg +, pyyaml +, tzlocal }: -with python3.pkgs; - buildPythonApplication rec { pname = "jrnl"; - version = "1.9.8"; + version = "2.7"; + format = "pyproject"; - src = fetchPypi { - inherit pname version; - sha256 = "d254c9c8f24dcf985b98a1d5311337c7f416e6305107eec34c567f58c95b06f4"; + src = fetchFromGitHub { + owner = "jrnl-org"; + repo = pname; + rev = "v${version}"; + sha256 = "1hyjjw9mxy73n3pkliaaif135h2sd4iy43pw9d5zynid5abnr3yz"; }; + nativeBuildInputs = [ poetry ]; + propagatedBuildInputs = [ - pytz six tzlocal keyring dateutil - parsedatetime pycrypto + ansiwrap + asteval + colorama + cryptography + keyring + parsedatetime + python-dateutil + pytz + pyxdg + pyyaml + tzlocal ]; - # No tests in archive - doCheck = false; + checkInputs = [ pytestCheckHook ]; + pythonImportsCheck = [ "jrnl" ]; meta = with lib; { homepage = "http://maebert.github.io/jrnl/"; description = "A simple command line journal application that stores your journal in a plain text file"; - license = licenses.mit; + license = licenses.gpl3Only; maintainers = with maintainers; [ zalakain ]; }; } diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 148ce73d290d..1dba2897b914 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -5428,7 +5428,7 @@ in jo = callPackage ../development/tools/jo { }; - jrnl = callPackage ../applications/misc/jrnl { }; + jrnl = python3Packages.callPackage ../applications/misc/jrnl { }; jsawk = callPackage ../tools/text/jsawk { };