Improve docs for Platforms and Framworks

This commit is contained in:
Ivan Kravets
2017-06-20 16:57:47 +03:00
parent 707384aeed
commit 6ad1ce5239
2 changed files with 24 additions and 18 deletions

2
docs

Submodule docs updated: ac1528773f...00924a1ed8

View File

@ -176,21 +176,22 @@ def generate_platform(name):
See the License for the specific language governing permissions and See the License for the specific language governing permissions and
limitations under the License. limitations under the License.
""") """)
p = PlatformFactory.newPlatform(name)
lines.append(".. _platform_%s:" % name) lines.append(".. _platform_%s:" % p.name)
lines.append("") lines.append("")
_title = "Platform ``%s``" % name lines.append(p.title)
lines.append(_title) lines.append("=" * len(p.title))
lines.append("=" * len(_title)) lines.append(":ref:`projectconf_env_platform` = ``%s``" % p.name)
lines.append("")
p = PlatformFactory.newPlatform(name)
lines.append(p.description) lines.append(p.description)
lines.append(""" lines.append("""
For more detailed information please visit `vendor site <%s>`_.""" % For more detailed information please visit `vendor site <%s>`_.""" %
p.vendor_url) p.vendor_url)
lines.append(""" lines.append("""
.. contents::""") .. contents:: Contents
:local:""")
# #
# Packages # Packages
@ -286,15 +287,18 @@ def generate_framework(type_, data):
lines.append(".. _framework_%s:" % type_) lines.append(".. _framework_%s:" % type_)
lines.append("") lines.append("")
_title = "Framework ``%s``" % type_ lines.append(data['title'])
lines.append(_title) lines.append("=" * len(data['title']))
lines.append("=" * len(_title)) lines.append(":ref:`projectconf_env_framework` = ``%s``" % type_)
lines.append("")
lines.append(data['description']) lines.append(data['description'])
lines.append(""" lines.append("""
For more detailed information please visit `vendor site <%s>`_. For more detailed information please visit `vendor site <%s>`_.
""" % data['url']) """ % data['url'])
lines.append(".. contents::") lines.append("""
.. contents:: Contents
:local:""")
lines.append(""" lines.append("""
Platforms Platforms
@ -418,14 +422,16 @@ Rapid Embedded Development, Continuous and IDE integration in a few
steps with PlatformIO thanks to built-in project generator for the most steps with PlatformIO thanks to built-in project generator for the most
popular embedded boards and IDE. popular embedded boards and IDE.
* You can list pre-configured boards using :ref:`cmd_boards` command or .. note::
`PlatformIO Boards Explorer <http://platformio.org/boards>`_ * You can list pre-configured boards by :ref:`cmd_boards` command or
* For more detailed ``board`` information please scroll tables below by `PlatformIO Boards Explorer <http://platformio.org/boards>`_
horizontal. * For more detailed ``board`` information please scroll tables below by horizontal.
""") """)
lines.append(".. contents::") lines.append("""
lines.append("") .. contents:: Vendors
:local:
""")
vendors = {} vendors = {}
for data in BOARDS: for data in BOARDS: