diff options
author | Nicolas Dechesne <nicolas.dechesne@linaro.org> | 2020-07-24 16:27:54 +0200 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2020-09-17 10:09:33 +0100 |
commit | c473fa229239752367c5d573160fc8738cf1907e (patch) | |
tree | f8520ba3aa3cf911333dbd31e38e9a52203a0285 /documentation/ref-manual/ref-devtool-reference.rst | |
parent | 4cd953989de42c7a83f666c23e077d53b016a1f1 (diff) | |
download | poky-c473fa229239752367c5d573160fc8738cf1907e.tar.gz |
sphinx: fix internal links
Many of the internal links were not converted probably from DocBook
using pandoc. After looking at the various patterns, the follow series
of 'naive' Python regexp were used to perform some additional
automatic conversion.
Also, since we rely on built-in glossary, all links to terms need to
use the sphinx :term: syntax.
This commit is generated using the following Python series of regexp:
line = re.sub("`+(\w+)`* <(\&YOCTO_DOCS_REF_URL;)?#var-\\1>`__",
":term:`\\1`",
line)
line = re.sub("`+do_([a-z_]+)`* <(\&YOCTO_DOCS_REF_URL;)?#ref-tasks-\\1>`__",
":ref:`ref-tasks-\\1`",
line)
line = re.sub("`+([a-z_\-\*\.]+).bbclass`* <(\&YOCTO_DOCS_REF_URL;)?#ref-classes-\\1>`__",
":ref:`\\1.bbclass <ref-classes-\\1>`",
line)
line = re.sub("`+([a-z_\-\*\.]+)`* <(\&YOCTO_DOCS_REF_URL;)?#ref-classes-\\1>`__",
":ref:`\\1 <ref-classes-\\1>`",
line)
line = re.sub("`Source Directory <(\&YOCTO_DOCS_REF_URL;)?#source-directory>`__",
":term:`Source Directory`",
line)
line = re.sub("`Build Directory <(\&YOCTO_DOCS_REF_URL;)?#build-directory>`__",
":term:`Build Directory`",
line)
line = re.sub("`Metadata <(\&YOCTO_DOCS_REF_URL;)?#metadata>`__",
":term:`Metadata`",
line)
line = re.sub("`BitBake <(\&YOCTO_DOCS_REF_URL;)?#bitbake-term>`__",
":term:`BitBake`",
line)
line = re.sub("`Images <(\&YOCTO_DOCS_REF_URL;)?#ref-images>`__",
":ref:`ref-manual/ref-images:Images`",
line)
line = re.sub("`Classes <(\&YOCTO_DOCS_REF_URL;)?#ref-classes>`__",
":ref:`ref-manual/ref-classes:Classes`",
line)
line = re.sub("`workspace <(\&YOCTO_DOCS_REF_URL;)?#devtool-the-workspace-layer-structure>`__",
":ref:`devtool-the-workspace-layer-structure`",
line)
line = re.sub("`Open-?Embedded b?B?uild s?S?ystem <(\&YOCTO_DOCS_REF_URL;)?#build-system-term>`__",
":term:`OpenEmbedded Build System`",
line)
line = re.sub("`(OpenEmbedded-Core )?(\(?OE-Core\)? )?<(\&YOCTO_DOCS_REF_URL;)?#oe-core>`__",
":term:`OpenEmbedded-Core (OE-Core)`",
line)
It won't catch multiline strings, but it catches a very large number
of occurences!
(From yocto-docs rev: 3f537d17de5b1fb76ba3bee196481984a4826378)
Signed-off-by: Nicolas Dechesne <nicolas.dechesne@linaro.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'documentation/ref-manual/ref-devtool-reference.rst')
-rw-r--r-- | documentation/ref-manual/ref-devtool-reference.rst | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/documentation/ref-manual/ref-devtool-reference.rst b/documentation/ref-manual/ref-devtool-reference.rst index 5bb1a64d99..b0c4bcc7a0 100644 --- a/documentation/ref-manual/ref-devtool-reference.rst +++ b/documentation/ref-manual/ref-devtool-reference.rst | |||
@@ -217,7 +217,7 @@ Git, checks out a branch for development, and applies any patches from | |||
217 | the recipe as commits on top. You can use the following command to | 217 | the recipe as commits on top. You can use the following command to |
218 | checkout the source files: $ devtool modify recipe Using the above | 218 | checkout the source files: $ devtool modify recipe Using the above |
219 | command form, ``devtool`` uses the existing recipe's | 219 | command form, ``devtool`` uses the existing recipe's |
220 | ```SRC_URI`` <#var-SRC_URI>`__ statement to locate the upstream source, | 220 | :term:`SRC_URI` statement to locate the upstream source, |
221 | extracts the source into the default sources location in the workspace. | 221 | extracts the source into the default sources location in the workspace. |
222 | The default development branch used is "devtool". | 222 | The default development branch used is "devtool". |
223 | 223 | ||
@@ -360,9 +360,9 @@ When you use the ``devtool upgrade`` command, you must supply the root | |||
360 | name of the recipe (i.e. no version, paths, or extensions), and you must | 360 | name of the recipe (i.e. no version, paths, or extensions), and you must |
361 | supply the directory to which you want the source extracted. Additional | 361 | supply the directory to which you want the source extracted. Additional |
362 | command options let you control things such as the version number to | 362 | command options let you control things such as the version number to |
363 | which you want to upgrade (i.e. the ```PV`` <#var-PV>`__), the source | 363 | which you want to upgrade (i.e. the :term:`PV`), the source |
364 | revision to which you want to upgrade (i.e. the | 364 | revision to which you want to upgrade (i.e. the |
365 | ```SRCREV`` <#var-SRCREV>`__), whether or not to apply patches, and so | 365 | :term:`SRCREV`), whether or not to apply patches, and so |
366 | forth. | 366 | forth. |
367 | 367 | ||
368 | You can read more on the ``devtool upgrade`` workflow in the "`Use | 368 | You can read more on the ``devtool upgrade`` workflow in the "`Use |
@@ -439,7 +439,7 @@ The target is the address of the target machine, which must be running | |||
439 | an SSH server (i.e. ``user@hostname[:destdir]``). | 439 | an SSH server (i.e. ``user@hostname[:destdir]``). |
440 | 440 | ||
441 | This command deploys all files installed during the | 441 | This command deploys all files installed during the |
442 | ```do_install`` <#ref-tasks-install>`__ task. Furthermore, you do not | 442 | :ref:`ref-tasks-install` task. Furthermore, you do not |
443 | need to have package management enabled within the target machine. If | 443 | need to have package management enabled within the target machine. If |
444 | you do, the package manager is bypassed. | 444 | you do, the package manager is bypassed. |
445 | 445 | ||
@@ -492,7 +492,7 @@ Creating the Workspace Layer in an Alternative Location | |||
492 | ======================================================= | 492 | ======================================================= |
493 | 493 | ||
494 | Use the ``devtool create-workspace`` command to create a new workspace | 494 | Use the ``devtool create-workspace`` command to create a new workspace |
495 | layer in your `Build Directory <#build-directory>`__. When you create a | 495 | layer in your :term:`Build Directory`. When you create a |
496 | new workspace layer, it is populated with the ``README`` file and the | 496 | new workspace layer, it is populated with the ``README`` file and the |
497 | ``conf`` directory only. | 497 | ``conf`` directory only. |
498 | 498 | ||