1
0
mirror of https://github.com/mpv-player/mpv synced 2025-01-23 16:13:39 +00:00

manpage: add table of contents to the HTML version

The reST contents directive is added to mpv.rst.

In wscript_build.py, the --strip-elements-with-class=contents option is
needed for the rst2man call in order to prevent the TOC from appearing
in mpv.1.
This commit is contained in:
Zhiming Wang 2016-12-13 19:21:30 -05:00 committed by wm4
parent 544110bf43
commit 870a6a11d9
2 changed files with 3 additions and 1 deletions

View File

@ -9,6 +9,8 @@ a media player
:Manual section: 1
:Manual group: multimedia
.. contents:: Table of Contents
SYNOPSIS
========

View File

@ -28,7 +28,7 @@ def _build_man(ctx):
name = 'rst2man',
target = 'DOCS/man/mpv.1',
source = 'DOCS/man/mpv.rst',
rule = '${RST2MAN} ${SRC} ${TGT}',
rule = '${RST2MAN} --strip-elements-with-class=contents ${SRC} ${TGT}',
install_path = ctx.env.MANDIR + '/man1')
_add_rst_manual_dependencies(ctx)