From 8820b0c3ed6967890c8bdec0a2354229bea9e250 Mon Sep 17 00:00:00 2001 From: Chad Jablonski Date: Fri, 18 Jun 2021 09:16:11 -0400 Subject: [PATCH 1/2] maintainers: add cjab --- maintainers/maintainer-list.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/maintainers/maintainer-list.nix b/maintainers/maintainer-list.nix index edf5901bf537..c7f69479b651 100644 --- a/maintainers/maintainer-list.nix +++ b/maintainers/maintainer-list.nix @@ -1883,6 +1883,12 @@ githubId = 2131991; name = "Elmo Todurov"; }; + cjab = { + email = "chad+nixpkgs@jablonski.xyz"; + github = "cjab"; + githubId = 136485; + name = "Chad Jablonski"; + }; ck3d = { email = "ck3d@gmx.de"; github = "ck3d"; From 11b44aaa1153222200cce4b4f1e053bee11f9c9a Mon Sep 17 00:00:00 2001 From: Chad Jablonski Date: Fri, 18 Jun 2021 09:32:24 -0400 Subject: [PATCH 2/2] programmer-calculator: init at 2.1 --- .../math/programmer-calculator/default.nix | 34 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 2 files changed, 36 insertions(+) create mode 100644 pkgs/applications/science/math/programmer-calculator/default.nix diff --git a/pkgs/applications/science/math/programmer-calculator/default.nix b/pkgs/applications/science/math/programmer-calculator/default.nix new file mode 100644 index 000000000000..0238e5333577 --- /dev/null +++ b/pkgs/applications/science/math/programmer-calculator/default.nix @@ -0,0 +1,34 @@ +{ lib, gccStdenv, fetchFromGitHub, ncurses }: + +gccStdenv.mkDerivation rec { + pname = "programmer-calculator"; + version = "2.1"; + + src = fetchFromGitHub { + owner = "alt-romes"; + repo = pname; + rev = "v${version}"; + sha256 = "1vvpbj24ijl9ma0h669n9x0z1im3vqdf8zf2li0xf5h97b14gmv0"; + }; + + buildInputs = [ ncurses ]; + + installPhase = '' + runHook preInstall + install -Dm 555 pcalc -t "$out/bin" + runHook postInstall + ''; + + meta = with lib; { + description = "A terminal calculator for programmers"; + longDescription = '' + Terminal calculator made for programmers working with multiple number + representations, sizes, and overall close to the bits + ''; + homepage = "https://alt-romes.github.io/programmer-calculator"; + changelog = "https://github.com/alt-romes/programmer-calculator/releases/tag/v${version}"; + license = licenses.gpl3Only; + maintainers = with lib.maintainers; [ cjab ]; + platforms = platforms.all; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index fdc6db56bff9..085fc5d8826d 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -30173,6 +30173,8 @@ in pcalc = callPackage ../applications/science/math/pcalc { }; + programmer-calculator = callPackage ../applications/science/math/programmer-calculator { }; + bcal = callPackage ../applications/science/math/bcal { }; pspp = callPackage ../applications/science/math/pspp { };