-
-
Notifications
You must be signed in to change notification settings - Fork 22
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
Forced URL scheme for multilanguage and multiversion #22
Comments
This assumption probably comes from Read the Docs, since this project was created after a discussion there readthedocs/readthedocs.org#557 (comment) |
Thanks for the reply. @jdillard Would you accept a patch for a configurable url? For instance something like: scheme = app.config.i18n_url_scheme or "/{lang}/{version}/{link}"
url = site_url + scheme.format(lang=app.builder.config.language, version=version, link=link) |
Correct, I had made it opinionated based on RTD's scheme just to get something out. Although, it looks like I forgot to make an issue to remind myself to circle back and fix it, nice catch and nice fix! PR's gladly accepted! I just did a quick test and that looks like that solution will work, it just may need some finagling to get everything aligned again. If you want to submit a first draft I can help clean it up if it needs any. |
I merged your changes (and mine) in and then realized it forced a multilanguage and multiversion scheme as a default and didn't like that so changed the behavior to only include That is all documented in the README now if you would like to test the master branch before I cut a new version. |
Great, thanks for the addition and for the adaptation ! |
Thanks for the contribution, this was a great step forward! I went ahead and released it as version I already tested it with some unique schemes I have in other projects and the configuration is much cleaner now. |
Hello,
Reading the code, I understand that you assume the page is published, using the version and language configuration, following the scheme :
https://<html_baseurl>/<language>/<version>/<page>.html
sphinx-sitemap/sphinx_sitemap/__init__.py
Lines 103 to 104 in 02bbe94
Is there a reason to force this construction? For instance, on our website, we use the construction:
https://<base>/<version>/<language>/<page>/html
What would be the way to make it work for our scheme?
Thanks
The text was updated successfully, but these errors were encountered: