From 738dce6b00d484e4e1f301198c93ce1356eab090 Mon Sep 17 00:00:00 2001 From: keni Date: Thu, 21 Feb 2019 20:32:36 -0500 Subject: [PATCH] set up for proper generation of Files file --- dat/.gitattributes | 1 + dat/GENFILES | 50 ++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 51 insertions(+) create mode 100755 dat/GENFILES diff --git a/dat/.gitattributes b/dat/.gitattributes index 782b4d01e..3bb273c5c 100644 --- a/dat/.gitattributes +++ b/dat/.gitattributes @@ -4,5 +4,6 @@ data.base NHSUBST symbols NHSUBST tribute NHSUBST +GENFILES NHSUBST * NH_filestag=(file%s_for_all_versions) ..files NH_filegenprog diff --git a/dat/GENFILES b/dat/GENFILES new file mode 100755 index 000000000..c360d940f --- /dev/null +++ b/dat/GENFILES @@ -0,0 +1,50 @@ +#!/usr/bin/perl +# NetHack 3.6 GENFILES $NHDT-Date: 1550799147 2019/02/22 01:32:27 $ $NHDT-Branch: NetHack-3.6.2-beta01 $:$NHDT-Revision: 1.0 $ +# Copyright (c) 2018 by Kenneth Lorber +# NetHack may be freely redistributed. See license for details. + +# 2 sections: +# *.lev entries are generated by reading *.des +# hardcoded entries are in __DATA__ + +($dir = $0) =~ s!^(.*/)(.*)!$1!; + +print "T (files generated by lev_comp at playground creation time)\n"; + +foreach $des (<$dir*.des>){ + open IN, "<", $des or warn("Can't open $des: $!"); + while(){ + m/^(MAZE|LEVEL):\s*"(.*?)"/ && do { + print "F $2.lev\n"; + }; + } + close IN; +} +while(){ + print; +} + +__DATA__ +T (tile files optionally generated for X ports at playground creation time) +F pet_mark.xbm +F rip.xpm +F x11tiles +T (files generated for Qt interface on Mac OS X) +F nethack.icns +F Info.plist +T (files generated for win32 at compile time) +F porthelp +F dlb.lst +T (files generated for win32 tty at compile time) +F ttyoptions +T (files generated for win32 gui at compile time) +F guioptions +T (files generated by makedefs at playground creation time) +F data +F dungeon.pdf +F options +F oracles +F quest.dat +F rumors +T (file generated by dgn_comp at playground creation time) +F dungeon