Private
Public Access
2
0

Travis CI and Documentation Generation improvements

* Use docker images from docker hub instead of building them on Travis
* Fix doxygen warnings for C/C++ Documentation
* Fix examples inclusion in documentation
* Modify Travis build matrix to include stages and additional jobs
* Update doxygen2jsdoc submodule
* Add doxyport submodule
* Generate documentation for each language in Travis
* Add sonar.java.binaries to sonar-scan.sh

Signed-off-by: Nicolas Oliver <dario.n.oliver@intel.com>
This commit is contained in:
Nicolas Oliver
2017-07-28 10:48:48 -03:00
parent 14bf91af44
commit e0a1862ce3
51 changed files with 486 additions and 434 deletions

View File

@@ -19,7 +19,7 @@ if (DOXYGEN_FOUND)
set (SPHINX_HTML_DIR "${CMAKE_CURRENT_BINARY_DIR}/html")
# doc .rst locations
set (SPHINX_DOC_LOATION "${CMAKE_CURRENT_SOURCE_DIR}")
set (SPHINX_DOC_LOCATION "${CMAKE_CURRENT_SOURCE_DIR}")
configure_file(
"${CMAKE_CURRENT_SOURCE_DIR}/conf.py.in"
@@ -31,7 +31,7 @@ if (DOXYGEN_FOUND)
${SPHINX_EXECUTABLE} -b html
-c "${BINARY_BUILD_DIR}"
-d "${SPHINX_CACHE_DIR}"
"${SPHINX_DOC_LOATION}"
"${SPHINX_DOC_LOCATION}"
"${SPHINX_HTML_DIR}"
COMMENT "Building HTML documentation with Sphinx"
)

View File

@@ -31,7 +31,7 @@ sys.path.insert(0, "@CMAKE_BINARY_DIR@/src/python/python2")
# ones.
extensions = [
'sphinx.ext.autodoc',
'sphinx.ext.viewcode',
'sphinx.ext.viewcode'
]
# Add any paths that contain templates here, relative to this directory.
@@ -131,7 +131,7 @@ html_theme_path = ['@SPHINX_THEME_DIR@']
# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ['_static']
#html_static_path = ['_static']
# Add any extra paths that contain custom files (such as robots.txt or
# .htaccess) here, relative to this directory. These files are copied

View File

@@ -12,12 +12,12 @@ Hello GPIO
Here is the simplest Gpio program in mraa.
.. literalinclude:: ../../../examples/python/hello_gpio.py
.. literalinclude:: ../../../../examples/python/hello_gpio.py
:prepend: import mraa
:start-after: import mraa
GPIO Interrupt (isr)
===================
====================
The GPIO module allows you to set an interrupt on a GPIO. This interrupt is
controlled by the mode that the 'edge' is in. Before setting another isr please
@@ -27,7 +27,7 @@ values.
**Note:** Galileo Gen1 only supports EDGE_BOTH
.. literalinclude:: ../../../examples/python/hello_isr.py
.. literalinclude:: ../../../../examples/python/hello_isr.py
:prepend: import mraa
:start-after: import mraa
@@ -44,11 +44,11 @@ The I2c module module has a number of different ways of interacting with the
i2c bus, including a number of overloaded read() calls and the writeReg()
helper function.
.. literalinclude:: ../../../examples/python/bmp85.py
.. literalinclude:: ../../../../examples/python/bmp85.py
:prepend: x = m.I2c(0)
:start-after: x = m.I2c(0)
.. literalinclude:: ../../../docs/i2c.txt
.. literalinclude:: ../../../../docs/i2c.txt
Pwm
===
@@ -56,7 +56,7 @@ Pwm
The PWM module is rather simple, note that different hardware support PWM
generation is various different ways so results may vary.
.. literalinclude:: ../../../examples/python/cycle-pwm3.py
.. literalinclude:: ../../../../examples/python/cycle-pwm3.py
:prepend: import mraa
:start-after: import mraa
@@ -67,7 +67,7 @@ The ADC is typically provided on a dedicated or shared SPI bus, this is
abstracted by the Linux kernel as spidev and abstracted again by mraa. It is
fairly simple in use.
.. literalinclude:: ../../../examples/python/aio.py
.. literalinclude:: ../../../../examples/python/aio.py
:prepend: import mraa
:start-after: import mraa
@@ -82,12 +82,12 @@ Here's a simple pair of programs comprising a sender and receiver pair.
Sender:
.. literalinclude:: ../../../examples/python/uart_sender.py
.. literalinclude:: ../../../../examples/python/uart_sender.py
:prepend: import mraa
:start-after: import mraa
Receiver:
.. literalinclude:: ../../../examples/python/uart_receiver.py
.. literalinclude:: ../../../../examples/python/uart_receiver.py
:prepend: import mraa
:start-after: import mraa

View File

@@ -6,7 +6,7 @@
Welcome to mraa's documentation!
================================
.. include:: ../../../docs/index.md
.. include:: ../../../../docs/index.md
:start-after: ==============
:end-before: ## API
@@ -41,13 +41,15 @@ a C library. Generally attaching gdb to python works well, build mraa with
debug symbols and set breakpoints either in the SWIG _wrap functions, the C++
method/functions or the underlying C function. More info can be found on the
C/C++ documentation:
* `Debugging <../debugging.html>`_
* `Building from source <../building.html>`_
API Changelog
=============
.. include:: ../../../docs/index.md
:start-after: API Changelog
`Changelog <../changelog.html>`_
Indices and tables
==================

View File

@@ -2,4 +2,14 @@
%feature("autodoc", "3");
#ifdef DOXYGEN
%include common_hpp_doc.i
%include gpio_class_doc.i
%include i2c_class_doc.i
%include pwm_class_doc.i
%include aio_class_doc.i
%include spi_class_doc.i
%include uart_class_doc.i
#endif
%include ../mraapython.i