1{ lib
2, fetchFromGitHub
3, openjdk
4, python3
5}:
6
7python3.pkgs.buildPythonApplication rec {
8 pname = "html5validator";
9 version = "0.4.2";
10 format = "setuptools";
11
12 src = fetchFromGitHub {
13 owner = "svenkreiss";
14 repo = "html5validator";
15 rev = "refs/tags/v${version}";
16 hash = "sha256-yvclqE4+2R9q/UJU9W95U1/xVJeNj+5eKvT6VQel9k8=";
17 };
18
19 propagatedBuildInputs = [
20 openjdk
21 ] ++ (with python3.pkgs; [
22 pyyaml
23 ]);
24
25 nativeCheckInputs = with python3.pkgs; [
26 hacking
27 pytestCheckHook
28 ];
29
30 preCheck = ''
31 export PATH="$PATH:$out/bin";
32 '';
33
34 meta = with lib; {
35 description = "Command line tool that tests files for HTML5 validity";
36 homepage = "https://github.com/svenkreiss/html5validator";
37 changelog = "https://github.com/svenkreiss/html5validator/releases/tag/v${version}";
38 license = licenses.mit;
39 maintainers = with maintainers; [ phunehehe ];
40 };
41}