Merge pull request #16560 from vrthra/dvtm-customize

dvtm: allow user configuration
This commit is contained in:
Joachim Fasting 2016-07-02 14:10:26 +02:00 committed by GitHub
commit 24b3fa1ae6
2 changed files with 15 additions and 5 deletions

View file

@ -1,13 +1,15 @@
{ stdenv, fetchurl, ncurses }:
{ stdenv, fetchurl, ncurses, customConfig ? null }:
stdenv.mkDerivation rec {
name = "dvtm-0.15";
meta = {
meta = with stdenv.lib; {
description = "Dynamic virtual terminal manager";
homepage = http://www.brain-dump.org/projects/dvtm;
license = stdenv.lib.licenses.mit;
platfroms = stdenv.lib.platforms.linux;
license = licenses.mit;
platfroms = platforms.linux;
maintainers = [ maintainers.vrthra ];
};
src = fetchurl {
@ -15,6 +17,10 @@ stdenv.mkDerivation rec {
sha256 = "0475w514b7i3gxk6khy8pfj2gx9l7lv2pwacmq92zn1abv01a84g";
};
postPatch = stdenv.lib.optionalString (customConfig != null) ''
cp ${builtins.toFile "config.h" customConfig} ./config.h
'';
buildInputs = [ ncurses ];
prePatch = ''

View file

@ -1376,7 +1376,11 @@ in
dvgrab = callPackage ../tools/video/dvgrab { };
dvtm = callPackage ../tools/misc/dvtm { };
dvtm = callPackage ../tools/misc/dvtm {
# if you prefer a custom config, write the config.h in dvtm.config.h
# and enable
# customConfig = builtins.readFile ./dvtm.config.h;
};
e2tools = callPackage ../tools/filesystems/e2tools { };