Description
We tried to follow this documentation and use the templates for documentation in our project Strimzi. However, we have run into problems with the assembly template. The template suggests that on the beginning of every assembly, we should save the parent context:
:parent-context: {context}
And restore it at the end of every assembly.:
:context: {parent-context}
However, the template suggests that every assembly should use the same variable parent-context
. And this works only on a very flat structure. Once you change the context on two levels you can very easily mess up the context for all the upper levels because the original context will be never restores.
As an example, you can check these two samples:
- Using an old template: https://github.com/strimzi/strimzi-kafka-operator/tree/modular-docs-parent-context/documentation/test
- Using the latest template: https://github.com/strimzi/strimzi-kafka-operator/tree/modular-docs-parent-context/documentation/test2
Just check these out and open them in your editor / render them and you will see how the context is never restored properly.
So far the solution we used in our docs was:
- Remove every
parent-context
- When the context is actually changed, save and restore the context, but always use the different variable to not override the other parent contexts
Can you please clarify if we are using it incorrectly or if it is a bug?