From 789bf1f3a26706520204fb3ffec510c3e326f4af Mon Sep 17 00:00:00 2001 From: Paul Belanger Date: Mon, 28 Sep 2015 15:52:20 -0400 Subject: [PATCH] Add docs for grafana-dashboards command Also rework index file to include README over a dedicated readme file. Change-Id: I70108fb627131e7a8bfec6e64cbfc093e65ca48b Signed-off-by: Paul Belanger --- doc/source/grafana-dashboard.rst | 53 ++++++++++++++++++++++++++++++++ doc/source/index.rst | 14 ++++----- doc/source/readme.rst | 1 - setup.cfg | 3 ++ 4 files changed, 62 insertions(+), 9 deletions(-) create mode 100644 doc/source/grafana-dashboard.rst delete mode 100644 doc/source/readme.rst diff --git a/doc/source/grafana-dashboard.rst b/doc/source/grafana-dashboard.rst new file mode 100644 index 0000000..422ae0a --- /dev/null +++ b/doc/source/grafana-dashboard.rst @@ -0,0 +1,53 @@ +================= +grafana-dashboard +================= + +SYNOPSIS +======== + +``grafana-dashboard`` [options] [...] + +DESCRIPTION +=========== + +``grafana-dashboard`` is a CLI command to update Grafana dashboards from yaml +files. + +OPTIONS +======= + +-h, --help Show the help. +--config-dir DIR Path to a config directory to pull \*.conf files from. This + file set is sorted, so as to provide a predictable parse + order if individual options are over-ridden. The set is + parsed after the file(s) specified via previous + --config-file, arguments hence over-ridden options in the + directory take precedence. +--config-file PATH Path to a config file to use. Multiple config files can be + specified, with values in later files taking precedence. The + default files used are: None. +-d, --debug Print debugging output(set logging level to DEBUG + instead of default WARNING level). +-v, --verbose Print more verbose output (set logging level to INFO + instead of default WARNING level). +--version Show program's version number and exit. + +COMMANDS +======== + +Update Command +-------------- + +``grafana-dashboard`` [options] update + +Updates each specified dashboard to the lastest layout from parsed yaml files. + +FILES +===== + +/etc/grafyaml/grafyaml.conf + +AUTHOR +====== + +.. include:: ../../AUTHORS diff --git a/doc/source/index.rst b/doc/source/index.rst index 2d5416b..0403aee 100644 --- a/doc/source/index.rst +++ b/doc/source/index.rst @@ -1,20 +1,18 @@ -.. grafyaml documentation master file, created by - sphinx-quickstart on Tue Jul 9 22:26:36 2013. - You can adapt this file completely to your liking, but it should at least - contain the root `toctree` directive. - Welcome to grafyaml's documentation! -======================================================== +==================================== -Contents: +.. include:: ../../README.rst + +Contents +======== .. toctree:: :maxdepth: 2 - readme installation usage contributing + grafana-dashboard Indices and tables ================== diff --git a/doc/source/readme.rst b/doc/source/readme.rst deleted file mode 100644 index a6210d3..0000000 --- a/doc/source/readme.rst +++ /dev/null @@ -1 +0,0 @@ -.. include:: ../../README.rst diff --git a/setup.cfg b/setup.cfg index d88efbe..a56a7b6 100644 --- a/setup.cfg +++ b/setup.cfg @@ -35,5 +35,8 @@ console_scripts = oslo.config.opts = grafyaml = grafana_dashboards.builder:list_opts +[pbr] +warnerrors = True + [upload_sphinx] upload-dir = doc/build/html