dwarf-fortress: Add "lazy pack", config flags and some comments.
This commit is contained in:
@@ -5,6 +5,10 @@
|
||||
, enableTWBT ? false, twbt
|
||||
, themes ? {}
|
||||
, theme ? null
|
||||
# General config options:
|
||||
, enableIntro ? true
|
||||
, enableTruetype ? true
|
||||
, enableFPS ? false
|
||||
}:
|
||||
|
||||
let
|
||||
@@ -36,11 +40,24 @@ let
|
||||
pathsToLink = [ "/" "/hack" "/hack/scripts" ];
|
||||
ignoreCollisions = true;
|
||||
|
||||
postBuild = lib.optionalString enableDFHack ''
|
||||
postBuild = ''
|
||||
# De-symlink init.txt
|
||||
cp $out/data/init/init.txt init.txt
|
||||
rm $out/data/init/init.txt
|
||||
mv init.txt $out/data/init/init.txt
|
||||
'' + lib.optionalString enableDFHack ''
|
||||
rm $out/hack/symbols.xml
|
||||
substitute ${dfhack_}/hack/symbols.xml $out/hack/symbols.xml \
|
||||
--replace $(cat ${dwarf-fortress-original}/hash.md5.orig) \
|
||||
$(cat ${dwarf-fortress-original}/hash.md5)
|
||||
'' + lib.optionalString enableTWBT ''
|
||||
substituteInPlace $out/data/init/init.txt \
|
||||
--replace '[PRINT_MODE:2D]' '[PRINT_MODE:TWBT]'
|
||||
'' + ''
|
||||
substituteInPlace $out/data/init/init.txt \
|
||||
--replace '[INTRO:YES]' '[INTRO:${unBool enableIntro}]' \
|
||||
--replace '[TRUETYPE:YES]' '[TRUETYPE:${unBool enableTruetype}]' \
|
||||
--replace '[FPS:NO]' '[FPS:${unBool enableFPS}]'
|
||||
'';
|
||||
};
|
||||
in
|
||||
|
||||
Reference in New Issue
Block a user