Commit 3bfa961c authored by Tomek Mrugalski's avatar Tomek Mrugalski 🛰

[#10,!3] Generated API is now an appendix

parent 0875cf30
......@@ -92,4 +92,4 @@ docgen:
# That's a bit of a hack, but we are making sure that devel target
# is always valid. The alternative is to make devel depend on all
# *.cc *.h files in the whole tree.
.PHONY: devel guide
.PHONY: devel guide docgen
......@@ -177,8 +177,8 @@ public:
for (auto cmd : cmds_) {
if (!first) {
f << ", ";
generateCmdLink(f, cmd.first);
}
generateCmdLink(f, cmd.first);
first = false;
}
......@@ -215,7 +215,6 @@ public:
bool first = true;
for (auto cmd : cmds_) {
first = true;
auto daemons = cmd.second->get("support");
for (auto d : daemons->listValue()) {
if (d->stringValue() == daemon) {
......@@ -239,7 +238,6 @@ public:
bool first = true;
for (auto cmd : cmds_) {
first = true;
auto daemon_hook = cmd.second->get("hook");
if (!daemon_hook || daemon_hook->stringValue() != hook) {
continue;
......@@ -263,7 +261,7 @@ public:
generateCopyright(f);
f << "<chapter xmlns=\"http://docbook.org/ns/docbook\" version=\"5.0\" xml:id=\"api\">"
f << "<appendix xmlns=\"http://docbook.org/ns/docbook\" version=\"5.0\" xml:id=\"api\">"
<< endl;
f << " <title>API Reference</title>" << endl;
......@@ -273,7 +271,7 @@ public:
// Generate actual commands references.
generateCommands(f);
f << "</chapter>" << endl;
f << "</appendix>" << endl;
ofstream file(OUTPUT.c_str(), ofstream::trunc);
file << f.str();
......
......@@ -92,9 +92,12 @@
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="netconf.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="faq.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
href="faq.xml"/>
<chapter xml:id="acknowledgments">
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="api.xml"/>
<appendix xml:id="acknowledgments">
<title>Acknowledgments</title>
<para>Kea is an open source project designed, developed, and maintained by Internet Systems
......@@ -133,10 +136,7 @@
<link xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="https://www.tcinet.ru/">Technical Center of Internet</link>
.</para>
</chapter>
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="api.xml"/>
</appendix>
<!-- TODO: Add bibliography section (mostly RFCs, probably) -->
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment