about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/tools/misc/replacement/default.nix
blob: dde607419cae11f195379495e4f102d26798cf37 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
{ lib
, fetchFromGitHub
, python3Packages
}:

python3Packages.buildPythonApplication rec {
  pname = "replacement";
  version = "0.4.4";

  disabled = python3Packages.isPy27;

  src = fetchFromGitHub {
    owner = "siriobalmelli";
    repo = "replacement";
    rev = "v${version}";
    sha256 = "0j4lvn3rx1kqvxcsd8nhc2lgk48jyyl7qffhlkvakhy60f9lymj3";
  };

  propagatedBuildInputs = with python3Packages; [
    ruamel-yaml
  ];

  nativeCheckInputs = with python3Packages; [
    pytestCheckHook
    sh
  ];

  meta = with lib; {
    homepage = "https://github.com/siriobalmelli/replacement";
    description = "A tool to execute yaml templates and output text";
    mainProgram = "replacement";
    longDescription = ''
        Replacement is a python utility
        that parses a yaml template and outputs text.

        A 'template' is a YAML file containing a 'replacement' object.

        A 'replacement' object contains a list of blocks,
        each of which is executed in sequence.

        This tool is useful in generating configuration files,
        static websites and the like.
    '';
    license = licenses.asl20;
    maintainers = with maintainers; [ siriobalmelli ];
  };
}