nur-packages

My NUR packages
git clone git://git.sikmir.ru/nur-packages
Log | Files | Refs | README | LICENSE

commit 31eea4ab6d9ff38caf4e8d3f9aaf259d909e0e62
parent b4bec4ca92b37e8df83af5f941804423b8167747
Author: Nikolay Korotkiy <sikmir@disroot.org>
Date:   Thu,  6 Jul 2023 00:20:58 +0400

Add mitzasql

Diffstat:
Mpkgs/default.nix | 1+
Apkgs/misc/mitzasql/default.nix | 36++++++++++++++++++++++++++++++++++++
2 files changed, 37 insertions(+), 0 deletions(-)

diff --git a/pkgs/default.nix b/pkgs/default.nix @@ -351,6 +351,7 @@ lib.makeScope newScope ( libnbcompat = callPackage ./misc/libnbcompat { }; md2html = callPackage ./misc/md2html { }; miband4 = callPackage ./misc/miband4 { }; + mitzasql = callPackage ./misc/mitzasql { }; modbus-tools = callPackage ./misc/modbus-tools { inherit (darwin.apple_sdk.frameworks) IOKit; }; diff --git a/pkgs/misc/mitzasql/default.nix b/pkgs/misc/mitzasql/default.nix @@ -0,0 +1,36 @@ +{ lib, fetchFromGitHub, python3Packages }: + +python3Packages.buildPythonApplication rec { + pname = "mitzasql"; + version = "1.4.4"; + + src = fetchFromGitHub { + owner = "vladbalmos"; + repo = "mitzasql"; + rev = version; + hash = "sha256-C/KecK8PJDn/MyUxtxFLjVnkra6pW9QoLY34FWkwQ+8="; + }; + + postPatch = '' + substituteInPlace setup.py \ + --replace "pygments ==2.7.4" "pygments" \ + --replace "mysql-connector-python ==8.0.22" "mysql-connector-python" \ + --replace "urwid ==2.1.2" "urwid" \ + --replace "appdirs ==1.4.4" "appdirs" + ''; + + propagatedBuildInputs = with python3Packages; [ appdirs pygments mysql-connector urwid ]; + + preBuild = '' + export HOME=$TMPDIR + ''; + + doCheck = false; # MySQL server required + + meta = with lib; { + description = "MySQL command line / text based interface client"; + homepage = "https://vladbalmos.github.io/mitzasql/"; + license = licenses.mit; + maintainers = [ maintainers.sikmir ]; + }; +}