-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Request of implementation: global substitutions #2173
Comments
There is some functionality like this in I think the easiest way to do this would be another transform though. Use I'd be happy to review a pull request to merge this upstream. (In which case you wouldn't need to |
Hi, I guess this is not considered an issue unless a project starts to be fairly big. I am not sure I have enough understanding of Sphinx to work on a pull request, but I'll see if it is not too hard. |
Hi again,
that I populate in
It seems to work and the speed up is impressive (40%) ! Only one thing does not work: the standard markup layout like |
Oh I got it! I create a simple text node.... But what should I do to have the text parsed? I have been looking to what @lehmannro suggested but I could not figured out how to do that. In my understanding one should add suitable entries in |
( |
Just for reference: https://github.com/missinglinkelectronics/sphinxcontrib-globalsubs |
Wanted to check-in here: @andreacassioli -- were you able to get further with this? One issue I run into still is exactly what you mentioned here:
This seems to be a problem that impacts |
I have a fairly large project, say 1000 files, and a set of say 40 substitutions. I use rst_prolog to pre-pend the set of substitutions to each file. This seems to slow quite a lot the doc generation, and my guess is that I need to:
That looks overkilling and useless to me. Why is there no global substitution table? I know that Docutils is where substitutions happen. But I guess there should be a way to add substitutions in a way pretty much we do with the default ones (date, version...).
If it were possible, one may just provide a python dictionary in conf.py. Or a specific markup
If it is not possible to hack on docutils, what about a role like
but that would be quite cumbersome.
The text was updated successfully, but these errors were encountered: