-
Notifications
You must be signed in to change notification settings - Fork 113
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
Allow optional doc themes #2170
Conversation
Confused as to what this one is for? For local builders to build on a preexisting setup? Wouldn't they be using venv? |
They are using venv, but that does not help, something must tell Sphinx to use different theme from my local venv. So venv on its own does not help, and the code was a nested But it's a good point, embedding my local theme into upstream was a bad idea, I'll change it to use envvars instead. |
It is already in docs extra dependencies and it is used as an extension later on, so it should be fine to have that dictate the theme |
b6d3029
to
5e41671
Compare
5e41671
to
3160047
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, however I was not able to enable custom theme using a variable:
> TMT_DOCS_THEME=renku_sphinx_theme:renku_sphinx_theme make docs
...
hatch run docs:html
make[1]: Entering directory '/home/psss/git/tmt/docs'
sphinx-build -b html -d _build/doctrees . _build/html
Running Sphinx v6.2.1
Theme error:
no theme named 'renku_sphinx_theme' found (missing theme.conf?)
The renku_sphinx_theme
python module is installed. Any other steps are needed?
What about |
Have you added it as |
|
3160047
to
88497cc
Compare
What am I doing wrong? (Python 3.12)
|
Did you install the theme? I started with this:
|
Turns out it has to be in |
I don't follow. Do I need to fix anything in my PR? |
Hatch uses its own environment orthogonal to Lines 155 to 157 in cf5e7bf
and that is what is used in the make file: Lines 42 to 43 in cf5e7bf
I usually prefer to run the codes manually so that I understand it better and have more control of the options. I also generally use sphinx-autobuild for this and make it as a pycharm configuration. If you guys want I can distribute some of these.
|
nono, just saying why it didn't work for me. Theme wasn't installed in the docs environment. fwiw, I really like https://sphinxawesome.xyz/ theme |
True, AFAICT, but since
Feel free to do so, please. I tried to start with |
Ah, I see, so I had the wrong name, now works fine. Thanks for clarification. |
Yep, that's one of my favorites as well, and the Renku doesn't look bad either. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for addressing all comments, I just propose a shorter heading and code block in e30045e.
Yeah, looks good. However, the
I have to admit that |
I noticed some issues with how specification was rendered in some themes, missing levels - not content, just levels in the left sidebar. Switching from RTD theme would be nice, although right now I am motivated by my own personal profit rather than forcing tmt project to switch - I don't like the RTD theme, there are better ones, and I often consult locally rendered tmt docs, why not enjoy it while reading? :) I'll be using Renku then, let's see :) |
dad9e4c
to
636064d
Compare
There was already some optionality, PR makes it a bit cleaner to add custom themes for experimenting without way too many nested `try/except` blocks.
636064d
to
3737c37
Compare
Indeed some sphinx themes are not fully compatible with each other, and some do not render clearly. It would be nice to use this and generate a few variants and pick out which ones are better formatted. For me |
I've found where I saved the themes I liked - this one was not mentioned yet here: https://shibuya.lepture.com/ |
/packit build |
There was already some optionality, PR makes it a bit cleaner to add custom themes for experimenting without way too many nested
try/except
blocks.