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

docs: translate remaining .md files to .rst #2083

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

jahn-junior
Copy link

Translated remaining Markdown files from #2010 to reStructuredText.

The contents of each page remain largely unchanged, with the main exceptions being:

Copy link
Collaborator

@lengau lengau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for doing this!

My comments are a combination of specific requests and general observations, some of which may be better for a separate task.

Manage a 12-factor app charm
============================

See also: `Juju | 12-factor app charms <https://juju.is/docs/juju/charmed-operator>`_
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this maybe a better destination for the link?

Prepare an OCI image for a 12-factor app charm
----------------------------------------------

Follow this `how-to guide <https://documentation.ubuntu.com/rockcraft/en/latest/how-to/build-a-12-factor-app-rock>`_
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Follow this `how-to guide <https://documentation.ubuntu.com/rockcraft/en/latest/how-to/build-a-12-factor-app-rock>`_
Follow this :external+rockcraft:doc:`how-to guide <how-to/build-a-12-factor-app-rock>`

docs/howto/manage-a-12-factor-app-charm.rst Show resolved Hide resolved

.. note::

The key optional with value ``False`` means that the charm will
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The key optional with value ``False`` means that the charm will
The key ``optional`` with value ``False`` means that the charm will

----------------

Extra services defined in the file
:literalref:`rockcraft.yaml <https://documentation.ubuntu.com/rockcraft/en/stable/reference/rockcraft.yaml/#services>`_
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
:literalref:`rockcraft.yaml <https://documentation.ubuntu.com/rockcraft/en/stable/reference/rockcraft.yaml/#services>`_
:literalref:`rockcraft.yaml <https://documentation.ubuntu.com/rockcraft/en/stable/reference/rockcraft.yaml/#services>`

This is subtle, but :literalref: is part of canonical-sphinx-extensions, so it messes up if you have the underscore afterwards. You'll get a warning during the build that looks something like this:

/home/lengau/Work/Code/charmcraft/docs/reference/extensions/fastapi-framework-extension.rst:215: WARNING: Mismatch: both interpreted text role prefix and reference suffix.

Comment on lines +12 to +13
file, but additional changes are then required to enable the charm to be
built with Charmcraft.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
file, but additional changes are then required to enable the charm to be
built with Charmcraft.
file, but additional changes are then required to build the charm with Charmcraft.

The ``tests/integration/test_charm.py`` file is the companion to
``src/charm.py`` for integration testing.

This file is created automatically by ``charmcraft init`` and it is
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not all profiles generate this file.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's change it to "profiles other than the one for 12-factor apps automatically create..."


See also: `How to write unit tests for a charm <https://juju.is/docs/sdk/write-a-unit-test-for-a-charm>`_

The ``tests/unit/test_charm.py`` file is the companion to
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here - not all profiles generate this file. I think specifically the 12-factor ones don't.

docs/reference/profile.rst Show resolved Hide resolved

.. code-block:: bash

curl 10.1.157:8000
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
curl 10.1.157:8000
curl 10.1.157.80:8000

Copy link
Contributor

@medubelko medubelko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We'll need to:

  • Fix all the indentation for the YAML code blocks; it needs to be based on two spaces or it won't render correctly.
  • Fix outstanding lint errors.

Comment on lines +889 to +890
``Other keys``
--------------
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
``Other keys``
--------------
Other keys
----------

Comment on lines +895 to +896
incorporated into CI processes. An example is
:literalref:`upstream source <https://github.com/canonical/charmcraft/blob/b22fcdba3b894004468abfbf45caa54d93fbf7d0/charmcraft/templates/init-simple/metadata.yaml.j2#L40-L43>`_.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
incorporated into CI processes. An example is
:literalref:`upstream source <https://github.com/canonical/charmcraft/blob/b22fcdba3b894004468abfbf45caa54d93fbf7d0/charmcraft/templates/init-simple/metadata.yaml.j2#L40-L43>`_.
incorporated into CI processes.

Let's cut this, because it isn't appropriate to provide such a specific example for an open-ended syntax.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants