1{ lib, stdenv, fetchurl, python, rcs, git, makeWrapper }:
2
3stdenv.mkDerivation rec {
4 pname = "src";
5 version = "1.28";
6
7 src = fetchurl {
8 url = "http://www.catb.org/~esr/src/${pname}-${version}.tar.gz";
9 sha256 = "1fkr5z3mlj13djz9w1sb644wc7r1fywz52qq97byw1yyw0bqyi7f";
10 };
11
12 nativeBuildInputs = [ makeWrapper ];
13 buildInputs = [ python rcs git ];
14
15 preConfigure = ''
16 patchShebangs .
17 '';
18
19 makeFlags = [ "prefix=${placeholder "out"}" ];
20
21 postInstall = ''
22 wrapProgram $out/bin/src \
23 --suffix PATH ":" "${rcs}/bin"
24 '';
25
26 meta = with lib; {
27 description = "Simple single-file revision control";
28 longDescription = ''
29 SRC, acronym of Simple Revision Control, is RCS/SCCS reloaded with a
30 modern UI, designed to manage single-file solo projects kept more than one
31 to a directory. Use it for FAQs, ~/bin directories, config files, and the
32 like. Features integer sequential revision numbers, a command set that
33 will seem familiar to Subversion/Git/hg users, and no binary blobs
34 anywhere.
35 '';
36 homepage = "http://www.catb.org/esr/src/";
37 changelog = "https://gitlab.com/esr/src/raw/${version}/NEWS";
38 license = licenses.bsd2;
39 platforms = platforms.all;
40 maintainers = with maintainers; [ calvertvl AndersonTorres ];
41 };
42}