Skip to content
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

Make internal doc links references #1506

Open
tonyandrewmeyer opened this issue Dec 18, 2024 · 1 comment
Open

Make internal doc links references #1506

tonyandrewmeyer opened this issue Dec 18, 2024 · 1 comment
Assignees
Labels
docs Improvements or additions to documentation small item

Comments

@tonyandrewmeyer
Copy link
Contributor

At the moment, many of the documentation pages have links like:

> See more: [`ops.CharmBase.config`](https://ops.readthedocs.io/en/latest/reference/ops.html#ops.CharmBase.config)

We should be able to make these references so that work even if the structure of the docs changes. {ref} and then a target, I think, but I'm not sure if the targets exist, or what they are named, since we are mixing ReST and Myst-Markdown.

@dwilding
Copy link
Contributor

From some testing, it looks like we do this on .md pages:

{attr}`ops.CharmBase.config`

On .rst pages it would be like this:

:attr:`ops.CharmBase.config`

@dwilding dwilding self-assigned this Dec 19, 2024
tonyandrewmeyer added a commit that referenced this issue Dec 19, 2024
Adjustments to the how-to guides:
* Links to the API reference are updated to the new location. I assume
that these can be references that will automatically resolve somehow,
but I'm not sure how to do that, so I opened #1506 and just fixed them
as full links for now (at least they'll work again).
* A few minor whitespace cleanups.
* Removed all the Harness sections, moving the Scenario sections up to
be "unit tests"
* Updated the Scenario sections to use ops.testing and Scenario 7
* Updated the secrets how-to to be more explicit about needing to remove
revisions if you create new ones.

[Live preview](https://ops--1507.org.readthedocs.build/en/1507/)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Improvements or additions to documentation small item
Projects
None yet
Development

No branches or pull requests

2 participants