Skip to content

Commit

Permalink
Fix docs indentation (#68)
Browse files Browse the repository at this point in the history
  • Loading branch information
MetRonnie authored Nov 20, 2024
1 parent ed3c2d5 commit 640381a
Showing 1 changed file with 25 additions and 25 deletions.
50 changes: 25 additions & 25 deletions cylc/flow/cfgspec/globalcfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
import os
from pathlib import Path
from sys import stderr
from textwrap import dedent, indent
from textwrap import dedent
from typing import List, Optional, Tuple, Any, Union

from contextlib import suppress
Expand Down Expand Up @@ -590,34 +590,34 @@
COMMA_SEPARATED_SECTION_NOTE = '''
.. note::
.. note::
This section can be a comma separated list.
This section can be a comma separated list.
.. spoiler:: Example
.. spoiler:: Example
For example:
For example:
.. code-block:: cylc
.. code-block:: cylc
[a, b]
setting = x
[a]
another_setting = y
[a, b]
setting = x
[a]
another_setting = y
Will become:
Will become:
.. code-block:: cylc
.. code-block:: cylc
[a]
setting = x
[b]
setting = x
[a]
another_setting = y
[a]
setting = x
[b]
setting = x
[a]
another_setting = y
Which will then be combined according to
:ref:`the rules for Cylc config syntax<syntax>`.
Which will then be combined according to
:ref:`the rules for Cylc config syntax<syntax>`.
'''

Expand Down Expand Up @@ -1165,9 +1165,9 @@ def default_for(
.. versionadded:: 8.0.0
"""):
with Conf('<install target>', desc="""
with Conf('<install target>', desc=dedent("""
:ref:`Host <Install targets>` on which to create the symlinks.
""" + COMMA_SEPARATED_SECTION_NOTE):
""") + COMMA_SEPARATED_SECTION_NOTE):
Conf('run', VDR.V_STRING, None, desc="""
Alternative location for the run dir.
Expand Down Expand Up @@ -1243,7 +1243,7 @@ def default_for(
.. versionadded:: 8.0.0
'''):
with Conf('<platform name>', desc=f'''
with Conf('<platform name>', desc=dedent('''
Configuration defining a platform.
Many of these settings have replaced those of the same name from
Expand All @@ -1253,7 +1253,7 @@ def default_for(
Platform names can be regular expressions: If you have a set of
compute resources such as ``bigmachine1, bigmachine2`` or
``desktop0000, .., desktop9999`` one would define platforms with
names ``[[bigmachine[12]]]`` and ``[[desktop[0-9]{{4}}]]``.
names ``[[bigmachine[12]]]`` and ``[[desktop[0-9]{4}]]``.
Cylc searches for a matching platform in the reverse
of the definition order to allow user defined platforms
Expand Down Expand Up @@ -1289,7 +1289,7 @@ def default_for(
.. versionadded:: 8.0.0
''' + indent(COMMA_SEPARATED_SECTION_NOTE, ' ' * 3)) as Platform:
''') + COMMA_SEPARATED_SECTION_NOTE) as Platform:
with Conf('meta', desc=PLATFORM_META_DESCR):
Conf('<custom metadata>', VDR.V_STRING, '', desc='''
Any user-defined metadata item.
Expand Down

0 comments on commit 640381a

Please sign in to comment.