-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Switch visibility of blocks based on only-directive #6301
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
Is the request to allow users to specify what sphinxs tags to expose during build? |
During the build process, the needed scopes would be accessible to administrators of the project only. The end user needs a way to switch between scopes. For this I'm thinking about two ways:
|
Hmm, why versions don't work for this use case? or maybe even better, subprojects. With versions, you can have distinct contents, but you need to keep updated both versions in the same repo, that may be hard to mantain. With subprojects, you can have two repos, one with simplified information and another one with the full docs. Another solution, is using tags, you can have both texts in the same rst page. You can insert tags based on env variables #4603. That way you can create two projects from one repo. If you want to have this in the same page, I think you can use the sphinx-tab extension, you can check an example here https://docs.readthedocs.io/en/stable/development/install.html#requirements |
I was thinking about using things like the sphinx tags or sphinx tab. Thanks for pointing out the reference on using tabs. Using different versions would be too confusing for end users since it's the same software / product version, but a different scope. I haven't thought about using subprojects yet. Would that be a way to use the |
Yes |
It seems that we already offered a solution to the user. Please, @maldag if there is something else missing here, let us know and re-open the issue. |
Details
This is a feature request for the following use case:
Implementation idea in RST
Usage of only-directive can filter what text is being processed by sphinx using tags in the commandline. Thus, multiple outputs of the same projects can be produced.
Similar to different versions represented by different branches in RTD, different scopes shall be available. So the visibility matrix for a single project will be:
The text was updated successfully, but these errors were encountered: