nur-packages

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

commit 9104b270bd8fa96af223946e5a6591b11c506986
parent 9ce549f9fbe1964d09f8640640fd01c4575f1662
Author: Nikolay Korotkiy <sikmir@gmail.com>
Date:   Sat, 24 Oct 2020 19:02:19 +0300

Add tatoebatools

Diffstat:
Mnix/sources.json | 14++++++++++++++
Mpkgs/default.nix | 1+
Apkgs/tools/dict/tatoebatools/default.nix | 30++++++++++++++++++++++++++++++
3 files changed, 45 insertions(+), 0 deletions(-)

diff --git a/nix/sources.json b/nix/sources.json @@ -851,6 +851,20 @@ "url": "https://github.com/selectel/supload/archive/70690682867713c68d7c6daa833a1013e79df407.tar.gz", "url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz" }, + "tatoebatools": { + "branch": "master", + "builtin": false, + "date": "2015-08-04T11:30:01Z", + "description": "A library for downloading, updating and iterating over monolingual data files from Tatoeba", + "homepage": "https://github.com/LBeaudoux/tatoebatools", + "owner": "LBeaudoux", + "repo": "tatoebatools", + "rev": "94669e5007ba225a792631668a81bc45476dd57a", + "sha256": "0lg2mnnxqj492h8r9fcf8z6yriv779z5562gmr9k10p60ha73api", + "type": "tarball", + "url": "https://github.com/LBeaudoux/tatoebatools/archive/94669e5007ba225a792631668a81bc45476dd57a.tar.gz", + "url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz" + }, "tilesets-cli": { "branch": "master", "builtin": false, diff --git a/pkgs/default.nix b/pkgs/default.nix @@ -172,6 +172,7 @@ lib.makeScope newScope ( supermercado = callPackage ./tools/geo/supermercado { }; supload = callPackage ./tools/misc/supload { }; taginfo-tools = callPackage ./tools/geo/taginfo-tools { }; + tatoebatools = callPackage ./tools/dict/tatoebatools { }; tilesets-cli = callPackage ./tools/geo/tilesets-cli { }; tpkutils = callPackage ./tools/geo/tpkutils { }; xfractint = callPackage ./tools/xfractint { }; diff --git a/pkgs/tools/dict/tatoebatools/default.nix b/pkgs/tools/dict/tatoebatools/default.nix @@ -0,0 +1,30 @@ +{ lib, python3Packages, sources }: +let + pname = "tatoebatools"; + date = lib.substring 0 10 sources.tatoebatools.date; + version = "unstable-" + date; +in +python3Packages.buildPythonApplication { + inherit pname version; + src = sources.tatoebatools; + + propagatedBuildInputs = with python3Packages; [ beautifulsoup4 pandas requests tqdm ]; + + checkInputs = with python3Packages; [ pytestCheckHook ]; + + disabledTests = [ + "test_iter_with_file" + "test_update_sentences_detailed" + "test_update_links" + "test_update_queries" + "test_update_up_to_date" + "test_update_with_not_language_pair" + ]; + + meta = with lib; { + inherit (sources.tatoebatools) description homepage; + license = licenses.mit; + maintainers = [ maintainers.sikmir ]; + platforms = platforms.unix; + }; +}