-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Is it possible to get read the docs to run a custom python script as part of the build? #2276
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
Comments
It's a hack but you can add your scripts to the bottom of conf.py. I have some shell scripts that I run by inserting subprocess.call() into conf.py. |
Sounds like you want to include your methods as a hook into one of the Sphinx events. Use a def setup(app):
... |
Thank you very much @zxiiro , @agjohnson . |
@TimKam Thanks for the link. Are you ready to close this issue? |
Is this possible when using Mkdocs? |
scripts/docs.sh was running sphinx build and then a custom post-process command. Move this post-process command into a seperate script that is invoked through the API extensions built into sphinx. This way servers like ReadTheDocs can get the invocation. This approach was discussed here: - readthedocs/readthedocs.org#2276 Then modified for our purposes. Signed-off-by: William Roberts <[email protected]>
scripts/docs.sh was running sphinx build and then a custom post-process command. Move this post-process command into a seperate script that is invoked through the API extensions built into sphinx. This way servers like ReadTheDocs can get the invocation. This approach was discussed here: - readthedocs/readthedocs.org#2276 Then modified for our purposes. Signed-off-by: William Roberts <[email protected]>
scripts/docs.sh was running sphinx build and then a custom post-process command. Move this post-process command into a seperate script that is invoked through the API extensions built into sphinx. This way servers like ReadTheDocs can get the invocation. This approach was discussed here: - readthedocs/readthedocs.org#2276 Then modified for our purposes. Signed-off-by: William Roberts <[email protected]>
All of these are really bad solutions... I have a While Configuration is not the place to run scripts. But, a command to generate documentation is. Why do it backwards? Please make it possible to do it right instead of adding another layer of duct tape around the problem. |
Hi @wvxvw , thanks for your interest on Read the Docs! For |
Specifically, I'd like to run a script that:
html/_sources
directory with these files.I have this script in place locally, but don't know if and how I can get it executed by the read the docs sever as part of the build process.
The text was updated successfully, but these errors were encountered: