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

"Edit on GitHub" fails when docs are in a different repo (git submodules) #1802

Open
ypid opened this Issue Nov 1, 2015 · 3 comments

Comments

Projects
None yet
3 participants
@ypid
Copy link

ypid commented Nov 1, 2015

@ericholscher ericholscher added the Bug label Nov 9, 2015

@stsewd

This comment has been minimized.

Copy link
Member

stsewd commented May 17, 2018

Hmm, I'm not sure how rtd can manage this since it only takes the repo url and the page name to built the edit url. We will need to inject the information about submodules in the theme context.

@stsewd

This comment has been minimized.

Copy link
Member

stsewd commented Nov 20, 2018

I was able to replicate this https://rtd-test-submodule.readthedocs.io/en/latest/, but as I mentioned, there is no way for rtd to guess what submodule each page belong to (in an easy way at least). A way of avoiding broken links could be hiding the links https://docs.readthedocs.io/en/latest/guides/remove-edit-buttons.html

Or you could change the github links in the template instead of hiding it https://github.com/rtfd/sphinx_rtd_theme/blob/4a3d790e61d7524baac698badee814cd286b1219/sphinx_rtd_theme/breadcrumbs.html#L37-L68. For the rtd footer, there isn't a way to change the links (well, probably it can be done with js).

Anyway, I think this should be handled by github, with a redirection. I'm changing this to a feature, isn't a bug.

@ypid

This comment has been minimized.

Copy link

ypid commented Nov 20, 2018

@stsewd Hoping for GitHub could work.

Note that I implemented a workaround which you could use a staring point: debops/docs#210

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment