2021-07-14 22:03:04 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub, writeText, conf ? null }:
|
2021-06-06 07:54:09 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "sfm";
|
2021-07-03 03:11:41 +00:00
|
|
|
version = "0.2";
|
2021-06-06 07:54:09 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "afify";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2021-07-03 03:11:41 +00:00
|
|
|
hash = "sha256-DwXKrSqcebNI5N9REXyMV16W2kr72IH9+sKSVehc5zw=";
|
2021-06-06 07:54:09 +00:00
|
|
|
};
|
|
|
|
|
2021-07-14 22:03:04 +00:00
|
|
|
configFile = lib.optionalString (conf!=null) (writeText "config.def.h" conf);
|
2021-06-06 07:54:09 +00:00
|
|
|
|
|
|
|
postPatch = lib.optionalString (conf!=null) "cp ${configFile} config.def.h";
|
|
|
|
|
|
|
|
installFlags = [ "PREFIX=$(out)" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Simple file manager";
|
|
|
|
homepage = "https://github.com/afify/sfm";
|
|
|
|
license = licenses.isc;
|
|
|
|
platforms = platforms.unix;
|
|
|
|
maintainers = with maintainers; [ sikmir ];
|
|
|
|
};
|
|
|
|
}
|