47 lines
1.0 KiB
Nix
47 lines
1.0 KiB
Nix
|
{ lib, fetchgit, buildGoPackage, texinfo }:
|
||
|
buildGoPackage rec {
|
||
|
pname = "goredo";
|
||
|
version = "0.12.3";
|
||
|
rev = version;
|
||
|
|
||
|
goPackagePath = "goredo";
|
||
|
|
||
|
src = fetchgit {
|
||
|
url = "git://git.cypherpunks.ru/goredo.git";
|
||
|
rev = "v${version}";
|
||
|
sha256 = "sha256-NXrBdr7grHkpdS8SO4keaiJHDJ1GgN0dKtZWKgexbc0=";
|
||
|
};
|
||
|
|
||
|
goDeps = ./deps.nix;
|
||
|
|
||
|
nativeBuildInputs = [ texinfo ];
|
||
|
|
||
|
postBuild = ''
|
||
|
(
|
||
|
cd go/src/goredo/doc
|
||
|
echo '${version}' >../VERSION
|
||
|
sh ./goredo.info.do goredo.info goredo.info goredo.info
|
||
|
)
|
||
|
'';
|
||
|
|
||
|
postInstall = ''
|
||
|
mkdir -p "$out/share/info"
|
||
|
cp go/src/goredo/doc/goredo.info "$out/share/info"
|
||
|
(
|
||
|
cd $out/bin
|
||
|
for f in redo redo-{always,cleanup,dot,ifchange,ifcreate,log,stamp,whichdo}; do
|
||
|
ln -s goredo $f
|
||
|
done
|
||
|
)
|
||
|
'';
|
||
|
|
||
|
outputs = [ "out" "info" ];
|
||
|
|
||
|
meta = with lib; {
|
||
|
description = "DJB redo written in Go";
|
||
|
homepage = "https://www.goredo.cypherpunks.ru";
|
||
|
license = licenses.gpl3;
|
||
|
platforms = platforms.linux ++ platforms.darwin;
|
||
|
};
|
||
|
}
|