shithub: choc

Download patch

ref: aa72812ca78c3318e726ade30accaf85ef865668
parent: eccaa5aacec2d1dc15c44b3b4854dd8748b6d4b1
author: Mike Swanson <mikeonthecomputer@gmail.com>
date: Sun Sep 16 00:51:35 EDT 2018

man: Generate Markdown versions of CMDLINE

--- a/man/.gitignore
+++ b/man/.gitignore
@@ -1,7 +1,11 @@
 CMDLINE.doom
+CMDLINE.doom.md
 CMDLINE.heretic
+CMDLINE.heretic.md
 CMDLINE.hexen
+CMDLINE.hexen.md
 CMDLINE.strife
+CMDLINE.strife.md
 INSTALL.doom
 INSTALL.heretic
 INSTALL.hexen
--- /dev/null
+++ b/man/CMDLINE.template.md
@@ -1,0 +1,8 @@
+# Command line parameters
+
+This is a full list of the supported command line parameters. A number of
+additional parameters are supported in addition to those present in the DOS
+version.
+
+@content
+
--- a/man/Makefile.am
+++ b/man/Makefile.am
@@ -17,12 +17,6 @@
 
 if HAVE_PYTHON
 
-if HAVE_WINDRES
-
-WIN32=-D_WIN32
-
-endif
-
 GENERATED_MAN_PAGES =               \
            @PROGRAM_PREFIX@doom.6         \
            default.cfg.5            \
@@ -52,6 +46,17 @@
 hexendocs_DATA   = INSTALL.hexen   CMDLINE.hexen
 strifedocs_DATA  = INSTALL.strife  CMDLINE.strife
 
+if HAVE_WINDRES
+
+WIN32=-D_WIN32
+
+doomdocs_DATA += CMDLINE.doom.md
+hereticdocs_DATA += CMDLINE.heretic.md
+hexendocs_DATA += CMDLINE.hexen.md
+strifedocs_DATA += CMDLINE.strife.md
+
+endif
+
 CLEANFILES = $(GENERATED_MAN_PAGES) $(SETUP_MAN_PAGES) \
              $(doomdocs_DATA) $(hereticdocs_DATA) \
              $(hexendocs_DATA) $(strifedocs_DATA)
@@ -78,6 +83,11 @@
                   -p $(srcdir)/CMDLINE.template \
                   $(top_srcdir)/src/ $(top_srcdir)/src/doom/ > $@
 
+CMDLINE.doom.md : CMDLINE.template.md $(top_srcdir)/src $(top_srcdir)/src/doom
+	$(DOCGEN) $(DOCGEN_COMMON_ARGS) \
+                  -M $(srcdir)/CMDLINE.template.md \
+                  $(top_srcdir)/src/ $(top_srcdir)/src/doom/ > $@
+
 CMDLINE.doom.wikitext : $(top_srcdir)/src $(top_srcdir)/src/doom
 	$(DOCGEN) $(DOCGEN_COMMON_ARGS) \
                   -w $(top_srcdir)/src/ $(top_srcdir)/src/doom/ > $@
@@ -108,6 +118,11 @@
                  -p $(srcdir)/CMDLINE.template \
                   $(top_srcdir)/src/ $(top_srcdir)/src/heretic/ > $@
 
+CMDLINE.heretic.md : CMDLINE.template.md $(top_srcdir)/src $(top_srcdir)/src/heretic
+	$(DOCGEN) $(DOCGEN_COMMON_ARGS) \
+                 -M $(srcdir)/CMDLINE.template.md \
+                  $(top_srcdir)/src/ $(top_srcdir)/src/heretic/ > $@
+
 INSTALL.heretic: INSTALL.template
 	$(srcdir)/simplecpp -DHERETIC $(WIN32) \
             -DLONG_GAME_NAME="@PACKAGE_SHORTNAME@ Heretic" \
@@ -135,6 +150,11 @@
                   -p $(srcdir)/CMDLINE.template \
                   $(top_srcdir)/src/ $(top_srcdir)/src/hexen/ > $@
 
+CMDLINE.hexen.md : CMDLINE.template.md $(top_srcdir)/src $(top_srcdir)/src/hexen
+	$(DOCGEN) $(DOCGEN_COMMON_ARGS) \
+                  -M $(srcdir)/CMDLINE.template.md \
+                  $(top_srcdir)/src/ $(top_srcdir)/src/hexen/ > $@
+
 INSTALL.hexen: INSTALL.template
 	$(srcdir)/simplecpp -DHEXEN $(WIN32) \
             -DLONG_GAME_NAME="@PACKAGE_SHORTNAME@ Hexen" \
@@ -172,6 +192,11 @@
                   -p $(srcdir)/CMDLINE.template \
                   $(top_srcdir)/src/ $(top_srcdir)/src/strife/ > $@
 
+CMDLINE.strife.md : CMDLINE.template.md $(top_srcdir)/src $(top_srcdir)/src/strife
+	$(DOCGEN) $(DOCGEN_COMMON_ARGS) \
+                  -M $(srcdir)/CMDLINE.template.md \
+                  $(top_srcdir)/src/ $(top_srcdir)/src/strife/ > $@
+
 INSTALL.strife: INSTALL.template
 	$(srcdir)/simplecpp -DSTRIFE $(WIN32) \
             -DLONG_EXE_NAME="@PROGRAM_PREFIX@strife" \
@@ -190,6 +215,7 @@
 EXTRA_DIST = $(man_MANS) $(MANPAGE_GEN_FILES)        \
              wikipages                               \
              CMDLINE.template                        \
+             CMDLINE.template.md                     \
              INSTALL.template                        \
              simplecpp