-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Config: Reuse docs/user/config-file/examples in django templates #10406
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
I would avoid making these examples run-able from the main repository. If we want to test these examples, we should create test-build branches that use them.
I'd also avoid symlinks -- we had pretty bad experiences in the past that I don't want to remember 🥲 That said, I think the best pattern we can follow here is just storing each different use-case in a YAML file and use |
@humitos With regard to building example configuration files, what I'd like to see is a continuous verification of example configuration files:
But I think that there is one very very important structural change that out-does all of the above: If we start to maintain all our user-facing examples in I'm not saying that the end-goal here is to over-load the main repo with the same kind of setups that test-builds is for. But I think that it can be a good idea to have a more structured approach and leverage that for better test integration. There's a separate issue on cleaning up test-builds. So hopefully this initiative can also give some new inspiration. Edit: An example of the above would be to simply check that the YAML code validates with our config parser.
Ah yeah, it's not my personal go-to solution for such cases, but I saw symlinks being used in
I think we should try to make it work without symlinks for sure, and you might be right that |
I'm closing this issue for now since we weren't able to prioritize and it fell off from our roadmap already. We can come back to it in the future if we hit this problem again. |
In #10301, we are starting to reuse configuration examples across different documentation files. We are also storing them in a way that they can potentially be built by Read the Docs using custom configuration file paths.
Once #10301 is merged, let's try to symlink these files into the django templates and see if we can ensure maximum consistency across all configuration file examples.
We need to ensure that the approach works for readthedocs-corporate as well (we might have to swap symlink source and target so the actual files get to exist in the Python package instead of the docs).
The text was updated successfully, but these errors were encountered: