2018-12-14 19:50:31 -08:00
|
|
|
{ stdenv, fetchFromGitHub, makeWrapper, perlPackages }:
|
2013-03-16 06:59:35 -07:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 05:41:18 -07:00
|
|
|
pname = "cloc";
|
2019-09-26 01:03:46 -07:00
|
|
|
version = "1.84";
|
2013-03-16 06:59:35 -07:00
|
|
|
|
2016-05-22 07:26:53 -07:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "AlDanial";
|
|
|
|
repo = "cloc";
|
2019-05-05 14:48:42 -07:00
|
|
|
rev = version;
|
2019-09-26 01:03:46 -07:00
|
|
|
sha256 = "14xikdwcr6pcnkk2i43zrsj88z8b3mrv0svbnbvxvarw1id83pnn";
|
2013-03-16 06:59:35 -07:00
|
|
|
};
|
|
|
|
|
2017-11-02 05:54:20 -07:00
|
|
|
setSourceRoot = ''
|
|
|
|
sourceRoot=$(echo */Unix)
|
|
|
|
'';
|
2015-10-05 08:46:49 -07:00
|
|
|
|
2018-12-14 19:50:31 -08:00
|
|
|
buildInputs = [ makeWrapper ] ++ (with perlPackages; [
|
|
|
|
perl AlgorithmDiff ParallelForkManager RegexpCommon
|
|
|
|
]);
|
2013-03-16 06:59:35 -07:00
|
|
|
|
|
|
|
makeFlags = [ "prefix=" "DESTDIR=$(out)" "INSTALL=install" ];
|
|
|
|
|
2016-05-22 07:26:53 -07:00
|
|
|
postFixup = "wrapProgram $out/bin/cloc --prefix PERL5LIB : $PERL5LIB";
|
|
|
|
|
2013-03-16 06:59:35 -07:00
|
|
|
meta = {
|
|
|
|
description = "A program that counts lines of source code";
|
2016-05-22 07:26:53 -07:00
|
|
|
homepage = https://github.com/AlDanial/cloc;
|
2013-03-16 06:59:35 -07:00
|
|
|
license = stdenv.lib.licenses.gpl2;
|
2016-05-22 07:26:53 -07:00
|
|
|
platforms = stdenv.lib.platforms.all;
|
2019-12-04 23:29:48 -08:00
|
|
|
maintainers = with stdenv.lib.maintainers; [ rycee ];
|
2013-03-16 06:59:35 -07:00
|
|
|
};
|
|
|
|
}
|