Yocto Project Documentation
 help / color / mirror / Atom feed
* [sphinx] updates as of Aug 5th.
@ 2020-08-05 21:54 Nicolas Dechesne
  2020-08-06  2:35 ` [docs] " Tim Orling
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Nicolas Dechesne @ 2020-08-05 21:54 UTC (permalink / raw)
  To: docs

hi there,

I will be away from the Interweb the next two weeks. So I wanted to
share some updates about how the YP docs migration to Sphinx is doing.
[it is a fairly long email].

To be honest, I wouldn't mind a little bit of help, and I will give
some hints about how you can help!

We are still working on publishing the current Sphinx docs on
yoctoproject.org, in the meantime, it's here for YP and Bitbake
documentation.

https://people.linaro.org/~nicolas.dechesne/yp-docs/html/index.html
https://people.linaro.org/~nicolas.dechesne/bitbake-docs/html/

All changes are pushed to the 'sphinx' branch in yocto-docs and in
bitbake trees.

Summary of the recent changes:

* I imported some CSS config from the current YP documentation, as a
result the look and feel is much closer to what we currently have.
There are still things to improve, but it's better on my eyes at
least.
* I added all images/figures, since they were missed by the automatic
conversion.
* I added a general index (it's a builtin Sphinx feature), which uses
all terms from the glossary. It is a nice feature, which looks
promising (it's a general index across all documents)
* I fixed a large amount to cross references (~2200 instances) to
terms and sections using a series of Python regexp and also another
400 instances were fixed manually.. when my regexp failed.
* I added extlinks Sphinx support to refer to external links/website,
and fixed them up in the source tree.
* I added intersphinx support which allows a Sphinx documentation
project to refer to section, terms, references from another Sphinx
documentation project. This is really good, since we can cross
reference bitbake terms directly from the YP documentation, eg..
:term:`bitbake:BB_FOO` will 'just work'.

The new documentation source code (.rst files) are really good to work
with, and it's much better to work with ReST files than XML, without
any surprise. The conversion is just a lot of work, and I already
spent some significant amount of work on it.. I hope you will find it
useful and I really hope it will achieve its goal to make it more
attractive to contribute to Yocto Project documentation project.

The way Sphinx works is that we have a single documentation project
that includes all the YP 'books'. It is an important change, we no
longer have X independent books, but have one project with all of
them. We need to work on how we want to publish the documentation
after the Sphinx migration.

Richard is trying to add support to easily switch between YP version
within the doc (e.g. like the Python doc), and we will host the 'old'
documentation as well. e.g. when choosing the 'thud' version, we want
to show a static page (not a Sphinx doc) that points to the thud html
doc.

And now here is the section you are all expecting the most! How can you help?

1. first you could learn about Sphinx and get familiar with the new
syntax. You should review all the patches one by one, to learn from
what I did! The sphinx documentation is good too. But looking at a
real world example is much easier.

2. there are still plenty of broken links.. it's mostly cross
references to section from one doc to another. DocBook used to have
'variables' (set in poky.ent) for each document (http link) and had
some macro to append an anchor to create a link. This whole mechanism
is not working well with Sphinx, and we should use Sphinx 'references'
(e.g. :ref: syntax) instead. Maybe some of that can be automated with
regexp, but I am not sure (very often it's multi line text and the
replacement pattern is not always obvious).. Just to give an idea
about how much work there is:
 $ git grep YOCTO_DOCS_.*_URL */*.rst  | wc -l
475

3. During the conversion from DocBook the 'code' or 'shell' sections
have been messed up, and is lost... it's quite unfortunate as this
will require some good amount of work to convert.. In Sphinx, we would
do this:
.. code-block:: shell
   $ cd $HOME/poky
   $ source oe-init-build-env
And it would render as we expect it to be.
This task is typically something that would distribute well among many
developers..

4. There are probably some other conversion hiccups at random places
(color, font type, text, ...), so I think we will have to do a careful
review of the HTML to find such issues and fix them. To be honest, I
think it's a rather good thing to do anyways

5. Theme or CSS improvements. We are using the standard 'read the doc'
theme. I would like to get feedback about the visual quality of the
resulting HTML project. If anyone has idea to improve it, that would
be much appreciated.

thanks!
nico

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2020-08-27 19:05 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-08-05 21:54 [sphinx] updates as of Aug 5th Nicolas Dechesne
2020-08-06  2:35 ` [docs] " Tim Orling
2020-08-06 18:33   ` Mark Morton
2020-08-06 22:39     ` Robert P. J. Day
2020-08-11 16:06 ` Robert Berger
2020-08-24 15:36   ` Nicolas Dechesne
2020-08-27 19:05     ` Robert Berger
2020-08-19 22:59 ` Richard Purdie
2020-08-24 15:48   ` Nicolas Dechesne
2020-08-24 16:26     ` Richard Purdie

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox