2018-12-08 12:34:40 +01:00
|
|
|
{ pkgs ? import <nixpkgs> {} }:
|
|
|
|
|
|
|
|
pkgs.stdenv.mkDerivation rec {
|
2018-12-08 14:04:26 +01:00
|
|
|
name = "dhall-text-simple";
|
2018-12-08 12:34:40 +01:00
|
|
|
version = "1.0.14";
|
|
|
|
dhall-version = "1.19.1";
|
|
|
|
|
|
|
|
src = pkgs.fetchurl {
|
|
|
|
url = "https://github.com/dhall-lang/dhall-haskell/releases/download/${dhall-version}/dhall-text-${version}-x86_64-linux.tar.bz2";
|
|
|
|
sha256 = "1z3rxl9fmm9lqg8mlis36aybmvg3dhdz9pbgs1vs4dxk33ig6qmj";
|
|
|
|
};
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/bin
|
2018-12-12 14:53:19 +01:00
|
|
|
DHALL_TO_TEXT=$out/bin/dhall-to-text
|
|
|
|
install -D -m555 -T dhall-to-text $DHALL_TO_TEXT
|
|
|
|
|
|
|
|
mkdir -p $out/etc/bash_completion.d/
|
|
|
|
$DHALL_TO_TEXT --bash-completion-script $DHALL_TO_TEXT > $out/etc/bash_completion.d/dhall-to-text-completion.bash
|
2018-12-08 12:34:40 +01:00
|
|
|
'';
|
|
|
|
}
|