Commit graph

106 commits

Author SHA1 Message Date
Mike Swanson
aa72812ca7 man: Generate Markdown versions of CMDLINE 2018-09-16 05:28:25 -07:00
Mike Swanson
eccaa5aace docgen: add Markdown output mode 2018-09-16 05:14:16 -07:00
Mike Swanson
aff22a2eaa INSTALL: Convert document to Markdown format 2018-09-16 04:53:38 -07:00
Simon Howard
779d73e4fd docgen: Fix links when capitalization doesn't match.
This fixes a couple of broken links on the wiki page when capitalization
doesn't match page name (since capitalization is significant in Mediawiki).
2018-05-27 20:36:09 -04:00
Simon Howard
74e0e0c740 docgen: Fix wiki text generation.
This got broken by some recent changes. As part of this, remove a
now-deleted wiki page and also add a Makefile target to build the page
(for Doom, at least).
2018-05-27 20:25:43 -04:00
Mike Swanson
e03c281d83 man: Remove quotes added in my prior commit for the WIN32 define
I have a habit of doing this in shell, and Make is not shell.  It was
overall harmless, but it looks cleaner when building to not see
"-D_WIN32" (quotes included) in the commands being run.
2018-03-17 10:50:07 -07:00
Mike Swanson
da54817037 win32: Include appropriate game-specific INSTALL files in Zips. 2018-03-17 10:46:16 -07:00
Simon Howard
9690b06aaa docgen: Fix spurious whitespace.
The text output mode included useless whitespace at the end of lines
and also occasionally generated lines containing nothing but
whitespace. Clean up the code that generates text output and fix
these bugs.
2018-03-16 21:48:55 -04:00
Simon Howard
ceefa5bbd9 docgen: Add 'game' and 'obscure' categories.
The "general options" section of the manpage(s) has become quite
cluttered, and some of the options are obscure things most people don't
need to know about. Move the really obscure ones into their own category
near the end of the manpage, and factor out the options used when
starting a game from the command line into their own section as well.

Also add some missing doc comments for Hexen command line options.
2018-03-16 21:25:20 -04:00
Mike Swanson
96e0123cd2 bash-completion: complete list of valid -gameversion parameters 2018-01-27 04:52:05 -08:00
Mike Swanson
da88012088 bash-completion: Build from actual shell script templates.
At some point, the Makefile was inerrantly modified so that it
generated manpage sources instead of shell script, making completions
very screwed up.
2018-01-27 04:49:08 -08:00
Jonathan Dowland
497514e39d better choice of substvar for chocolate-server.6 2018-01-15 19:18:52 +00:00
Jonathan Dowland
433230aa40 man: Fix simplecpp -D arguments 2018-01-15 19:10:52 +00:00
Jonathan Dowland
ccfbd4a046 bash-completion: run docgen with -z argument 2018-01-15 19:10:16 +00:00
Jonathan Dowland
69b8043958 fix typo @PACKAGE_SHORTNAME + '@' 2018-01-15 19:01:53 +00:00
Simon Howard
40811c8eaa INSTALL: Update patch file links.
The ftp.idsoftware.com server died several months back. Some context:
<https://www.doomworld.com/forum/topic/96999-rip-ftpidsoftwarecom/>

Instead, point at the mirrors found in the idgames repository, using
the gamers.org version since this is the canonical copy everything else
mirrors from. Unfortunately it's not possible to point at the Doomworld
idgames interface since the patches don't appear in the database there.
2018-01-14 23:02:52 -05:00
Jonathan Dowland
45880bd205 Implement suggestions from Fabian. Thanks! 2018-01-09 17:19:49 +00:00
Jonathan Dowland
d0aca32411 don't build chocolate-setup.6 anymore; more subs
Build chocolate-game-setup.6 directly instead of building
chocolate-setup.6 and copying it to for each game. Apply
substitutions to the template text to replace Chocolate,
chocolate etc., as well as substituting the proper default
cfg equivalent (e.g. heretic.cfg) for each game.
2018-01-09 17:19:49 +00:00
Jonathan Dowland
32ccfe015a expand docgen/default.cfg.template substitutions
Move to a "substs" hash in docgen which contains pairs of strings
to substitute. Populate @GAME@, @GAME_UPPER@ and @CFGFILE@ based
on the game supplied via -g.

Make the corresponding substitutions in default.cfg.template. Now
all of {default,heretic,hexen,strife}.cfg.5 are correct for the
respective game.
2018-01-09 17:19:49 +00:00
Jonathan Dowland
f515c88a96 install.template: move definitions to Makefile
Define and pass LONG_EXE_NAME and LONG_GAME_NAME within the
controlling Makefile when generating INSTALL.*, instead of
deriving their values within the template depending on whether
DOOM/HERETIC/HEXEN/STRIFE are defined.

This means we can incorporate the values from @PROGRAM_PREFIX@
and @PACKAGE_SHORTNAME@, instead of hardcoding chocolate- and
Chocolate, respectively.
2018-01-09 17:19:49 +00:00
Jonathan Dowland
c1f553b92a further manpage substitutions and fixes
Convert chocolate-setup.6 into a template file and generate outputs
based on @PROGRAM_PREFIX@.

Add @PACKAGE_SHORTNAME@ to the list of parameters handed to docgen
and make appropriate substitutions in the manpage templates.
2018-01-09 17:19:49 +00:00
Jonathan Dowland
e0b8a7e0a9 overhaul manpages, add parameters
This is in order to better support derivative engines.

Rework the manpages to be parameterized with @PROGRAM_PREFIX@ and
@PACKAGE_NAME@. Alter the `docgen` generator to substitute those
parameters. Supply those parameters via the autofoo Makefile.

Adjust the fixed path chocolate-server.6 to be generated from
server.template, similar to doom.template -> chocolate-doom.6.

Further work is required, not least renaming chocolate-setup.6,
but several further parameterizations.
2018-01-09 17:19:49 +00:00
Fabian Greffrath
a28f58da05 Merge branch 'master' into sdl2-branch 2017-04-24 14:46:31 +02:00
Mike Swanson
7f4e1ae124 bash-completion: Use autoconf substitutions for the chocolate name
Introduce a new PROGRAM_SPREFIX variable in configure.ac, which is
basically identical to PROGRAM_PREFIX but without the trailing hyphen.
PROGRAM_PREFIX was also redefined so that it bases its name from
PACKAGE_SHORTNAME, reducing the number of hardcoded chocolates in the
source.
2017-03-05 18:43:22 -08:00
Simon Howard
9401e974b2 docgen: Fix script.
Apparently caused by previous botched merge commit.
2017-01-30 23:00:41 -05:00
Simon Howard
c5af517b3b Merge remote-tracking branch 'origin/master' into sdl2-branch 2017-01-30 22:53:36 -05:00
Mike Swanson
765f864d84 man: make scripts Python2 compatible again.
My last commits broke functionality for Python2, but it's relatively
simple to fix.

open() becomes io.open() -- it effectively does nothing for Python3,
but for Python2 it uses a backported version of the open() call.

Python2 uses bytes and strings interchangably, but I needed to use
stdout.sys.buffer for writing arbitrary bytes data to stdout.
Conditionally call the appropriate stream depending on Python version.
2017-01-21 07:13:08 -08:00
Mike Swanson
d0c36735aa man: Make sure to add new lines in the last commit. 2017-01-19 13:03:00 -08:00
Mike Swanson
bf3747bfdd man/{docgen,simplecpp}: Force UTF-8 reading and writing regardless of locale
When encountering non-ASCII UTF-8 characters in source files (as
exists in Crispy Doom), the Python scripts would fail to work with
a UnicodeDecodeError if the locale was not a UTF-8 one (eg, the C
locale as encountered in chroot build environments).

Let's just use UTF-8 on both open() and replace print() statements with
sys.stdout.buffer.write().  This guarantees that all input and output is
UTF-8 regardless.
2017-01-19 12:48:35 -08:00
Simon Howard
166e2bca93 Merge remote-tracking branch 'origin/master' into sdl2-branch 2017-01-14 21:55:08 +00:00
Simon Howard
0d083b8565 INSTALL: Fix .lha filename extension.
LHA is the name of the tool, and .lzh is the extension used for files
of this format.
2017-01-14 21:48:45 +00:00
Zvonimir Bužanić
85b0d244c8 Update year 2016-10-20 23:03:54 +02:00
Simon Howard
490def9eb3 man: Fix build to allow out-of-tree builds.
For out-of-tree builds we must specify the full paths to source files
using $(srcdir). Do this for all the template files and clean up some
of the confusing and inconsistent usage of source dir paths already in
place.
2016-07-18 00:07:43 -04:00
Simon Howard
aca532db25 docgen: Read included templates from relative path.
When interpreting a template file that uses the @include statement, we
must read the included file from a path relative to the first template
file, rather than relative to the working directory when invoking the
script. This will allow us to do out-of-tree builds.
2016-07-18 00:02:58 -04:00
Mike Swanson
1c5973e4af Use SDL_GetPrefPath for the configuration directory.
The function requires two arguments: an organization name and an
application name.  Let’s set the organization name to an empty string.
This will not cause issues on POSIX-compliant systems, and hopefully
not on other kinds of systems too.  This just avoids an extra
directory to the configuration path.

This should pull Chocolate Doom into compliance with the XDG Base
Directory Specification, resolving #597.
2016-07-15 01:28:44 -07:00
Jonathan Dowland
ec90c9fa06 INSTALL.template: remove spare "compatible"
Edit via GitHub UI
2016-06-27 06:40:06 +01:00
Simon Howard
29a06c4e4d INSTALL: Add comment about using FreeDM.
Now that this is usable it's good to include this in the setup
instructions.
2016-06-26 18:54:05 -04:00
Simon Howard
d36dafa3fc Merge remote-tracking branch 'origin/master' into sdl2-branch 2016-06-04 19:36:32 -04:00
Jonathan Dowland
6cd7d53a27 Update INSTALL.template
Add freedm.wad to the list of IWADs that can be used for chocolate-doom.

Closes: #666.
2016-03-24 21:26:12 +00:00
Simon Howard
826d2a09fa Update Doomworld URLs.
Doomworld is now available over https: so there's no reason to link
to unencrypted http: URLs (which are just redirect anyway). Also the
idgames interface URLs have changed.
2016-02-28 14:30:31 -05:00
Simon Howard
6ad2f405b9 Refer to SDL2 versions of libraries in docs.
Helps to be accurate.
2016-02-28 14:26:25 -05:00
Rodrigo Rebello
86cb29b693 Avoid use of '$<' and '$^' in Makefile rules
Versions of make other than GNU make don't support automatic variables
in explicit rules, only in suffix (implicit) ones.

This fixes the build on FreeBSD (and possibly other BSD variants), which
was failing with errors like:

cp  chocolate-doom-setup
usage: cp [-R [-H | -L | -P]] [-f | -i | -n] [-alpvx] source_file target_file
       cp [-R [-H | -L | -P]] [-f | -i | -n] [-alpvx] source_file ... target_directory
*** Error code 64

Stop.
2015-12-30 11:36:28 -02:00
Fabian Greffrath
cb4848b8da bash-completion: allow multiple files with the same extensions
passed to the same switch, e.g. -file a.wad b.wad.

Also, fix the -setmen typo.
2015-10-30 08:53:37 +01:00
Fabian Greffrath
278cd34b3e bash-completion: fix syntax error
_filedir expects a regex as an argument, not a lose list of file extensions
2015-10-30 08:25:21 +01:00
Mike Swanson
c3e5879502 bash-completion: Detect the appropriate directory for installation 2015-10-27 09:30:24 -07:00
Fabian Greffrath
ad37a8ff33 Bash-Completion: First attempt at programatically creating the parameters list 2015-10-26 18:44:30 +01:00
Fabian Greffrath
d9738a5372 man: add a bash-completion scriptlet
Only one for all four games and only static for the time being.

In the long term, we should modify the docgen script to emit the
possible valid command line parameters and their additional options
and thus create separate bash-completion scriptlets for all four
games.
2015-10-18 11:48:57 +02:00
Simon Howard
7d51bb2262 man: Add documentation for IWAD search paths.
We now search in a bunch of different directories in order to find
IWAD files to use to play with, and the logic is a bit complicated.
Add some hopefully friendly documentation to explain where people
can put their IWAD files to play with.

Part of #597.
2015-08-23 16:12:54 -04:00
Fabian Greffrath
4ee95eb27f man: fix the very last hyphen used as minus sign 2015-05-01 13:54:36 +02:00
Fabian Greffrath
d5fe304162 man: fix one last hyphen used as minus sign 2015-05-01 13:50:45 +02:00