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

Enhance config options - separate documents #40

Open
Lennonka opened this issue Apr 4, 2021 · 1 comment
Open

Enhance config options - separate documents #40

Lennonka opened this issue Apr 4, 2021 · 1 comment

Comments

@Lennonka
Copy link

Lennonka commented Apr 4, 2021

Hello!

It would be very useful to have options in the conf.py to define a set of separate documents that would be generated from different "master" docs, similar to the built-in latex builder.

For example: Let's have this Sphinx project:

  • conf.py, Makefile
  • index.rst
  • documentA.rst
  • documentB.rst

I want document A and document B in separate output files and use different stylesheets.

I could define that in the conf.py as follows:

docx_documents = [
  ('documentA', 'Document01.docx', dotx_stylesheetA, toctree_only),
  ('documentB',  'Document02.docx', dotx_stylesheetB, toctree_only),
  ...
]

Then make docx would build Document01.docx from the file documentA.rst using docx_stylesheetA and Document02.docx from the file documentB.rst using docx_stylesheetB.

Perhaps code from the latex builder could be reused.

Thanks a lot for looking into this!

@hugobuddel
Copy link
Collaborator

Thanks @Lennonka. We made this tool to scratch our own itch, and it seems that others like it too so we should step up our game.

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