Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

not clear how to set the tocDepth attribute #99

Closed
dkg opened this issue Feb 6, 2021 · 2 comments
Closed

not clear how to set the tocDepth attribute #99

dkg opened this issue Feb 6, 2021 · 2 comments

Comments

@dkg
Copy link
Contributor

dkg commented Feb 6, 2021

The tocDepth attribute changes the default depth of the generated table of contents.

It's not clear to me how to get a markdown-sourced document to emit this attribute in a way that xml2rfc will respect it.

This came up in the OpenPGP WG's attempt to refresh the cryptographic standards for OpenPGP. See Derek Atkins message which says:

The ToC doesn't include anything beyond x.y.z

This isn't urgent, but insofar as we're looking at revisions to RFC 4880 it'd be nice to be able to compare the document structure by seeing the same level of ToC depth (RFC 4880 has a ToC 4 levels deep).

@cabo
Copy link
Owner

cabo commented Feb 6, 2021

Here is an example of YAML that does this:

...
ipr: trust200902
area: Internet
# wg: CoRE Working Group
kw: Internet-Draft
cat: info

pi:
  toc: yes
  tocdepth: 4
  sortrefs: yes
  symrefs: yes

author:
      -
        name: Carsten Bormann
...

Note that this looks like a PI (processing instruction), because that was the way this was done in RFCXMLv2 and kramdown-rfc is trying to be stable.

@dkg
Copy link
Contributor Author

dkg commented Feb 15, 2021

thanks, this fix works for me.

@dkg dkg closed this as completed Feb 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants