aboutsummaryrefslogtreecommitdiffstats
path: root/util/travis_docs.sh
diff options
context:
space:
mode:
authorGravatar skullydazed <skullydazed@users.noreply.github.com>2018-03-21 23:50:38 -0700
committerGravatar Jack Humbert <jack.humb@gmail.com>2018-03-22 02:50:38 -0400
commit7c9d5ace143d3cc6d767a354acde814926d566fd (patch)
tree1f2b581b6c9f6278a9e180bfcc8dd86b0a7fd2ef /util/travis_docs.sh
parentf0932a8716dc946322c5ebae7f75eaa275c6220c (diff)
downloadqmk_firmware-7c9d5ace143d3cc6d767a354acde814926d566fd.tar.gz
Generate API docs from source code comments (#2491)
* Generate api docs from source code * Add a bunch of doxygen comments * more doxygen comments * Add the in-progress api docs * script to generate docs from travis * Add doc generation to the travis job * make travis_docs.sh commit the work it does * make sure the docs script exits cleanly
Diffstat (limited to 'util/travis_docs.sh')
-rw-r--r--util/travis_docs.sh14
1 files changed, 14 insertions, 0 deletions
diff --git a/util/travis_docs.sh b/util/travis_docs.sh
new file mode 100644
index 000000000..ec553952c
--- /dev/null
+++ b/util/travis_docs.sh
@@ -0,0 +1,14 @@
+#!/bin/bash
+
+source util/travis_push.sh
+
+if [[ "$TRAVIS_COMMIT_MESSAGE" != *"[skip docs]"* ]] ; then
+ if git diff --name-only ${TRAVIS_COMMIT_RANGE} | grep -e '^quantum/' -e '^tmk_core/' -e '^docs/api_.*'; then
+ echo "Generating API docs..."
+ rm -rf doxygen
+ doxygen Doxyfile
+ moxygen -a -g -o -q docs/api_%s.md doxygen/xml
+ git add docs/api_*
+ git commit -m'autogenerated api docs for ${TRAVIS_COMMIT_RANGE}' || true
+ fi
+fi