X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=blobdiff_plain;f=make-directive-index.py;h=2ff304fddc1ca14f743c58409b1d6d24f5ae5779;hp=ab40997a98bb928cfc463ac4becb893e07289b2a;hb=0452ffebbbb00a30894721666d81933425d182c7;hpb=d970bd6d39f808b29a804050747c0883fcc2784b;ds=sidebyside diff --git a/make-directive-index.py b/make-directive-index.py index ab40997a9..2ff304fdd 100755 --- a/make-directive-index.py +++ b/make-directive-index.py @@ -19,11 +19,12 @@ import sys import collections -import xml.etree.ElementTree as tree import re +from xml_helper import * +from copy import deepcopy TEMPLATE = '''\ - + systemd.directives @@ -85,6 +86,16 @@ TEMPLATE = '''\ + + Network directives + + Directives for configuring network links through the + net-setup-link udev builtin and networks through + systemd-networkd. + + + + Journal fields @@ -137,6 +148,14 @@ TEMPLATE = '''\ + + Constants + + Various constant used and/or defined by systemd. + + + + Miscellaneous options and directives @@ -146,6 +165,15 @@ TEMPLATE = '''\ + + Files and directories + + Paths and file names referred to in the + documentation. + + + + Colophon @@ -159,13 +187,14 @@ referring to {pages} individual manual pages. ''' def _extract_directives(directive_groups, formatting, page): - t = tree.parse(page) + t = xml_parse(page) section = t.find('./refmeta/manvolnum').text pagename = t.find('./refmeta/refentrytitle').text + + storopt = directive_groups['options'] for variablelist in t.iterfind('.//variablelist'): klass = variablelist.attrib.get('class') storvar = directive_groups[klass or 'miscellaneous'] - storopt = directive_groups['options'] #