diff options
| author | Linus Jahn <lnj@kaidan.im> | 2020-04-01 14:51:18 +0200 |
|---|---|---|
| committer | Linus Jahn <lnj@kaidan.im> | 2020-04-01 15:26:45 +0200 |
| commit | 4a09a18ff1d786c5fdea7b1992f6937fa7cbc833 (patch) | |
| tree | 487afb6da9699b01a034f5ce4dede6ffde372025 /tests/travis/push-documentation | |
| parent | aac82e6884a0db5345d3f43b1916f725349b2e4c (diff) | |
| download | qxmpp-4a09a18ff1d786c5fdea7b1992f6937fa7cbc833.tar.gz | |
actions: Push documentation to doc.qxmpp.org
Diffstat (limited to 'tests/travis/push-documentation')
| -rwxr-xr-x | tests/travis/push-documentation | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/tests/travis/push-documentation b/tests/travis/push-documentation new file mode 100755 index 00000000..ed5609a8 --- /dev/null +++ b/tests/travis/push-documentation @@ -0,0 +1,47 @@ +#!/bin/bash + +# Add ssh push key +eval "$(ssh-agent -s)" +echo $PUSH_KEY_REPO_DOC_QXMPP_ORG | base64 -d | unxz | ssh-add - + +# Set up git +git config --global user.email "docsbot@qxmpp.org" +git config --global user.name "QXmpp Docs Bot" + +# +# Build documentation +# + +echo '-------------------------------------------' +echo 'Building documentation' +echo '-------------------------------------------' + +mkdir build +cd build + +cmake .. -DBUILD_DOCUMENTATION=ON + +make doc + +# +# Push documentation +# + +echo '-------------------------------------------' +echo 'Cloning doc.qxmpp.org repository' +echo '-------------------------------------------' + +git clone ssh://git@github.com/qxmpp-project/doc.qxmpp.org + +echo '-------------------------------------------' +echo 'Commiting and pushing documentation' +echo '-------------------------------------------' + +# delete old dev docs +rm -rf doc.qxmpp.org/qxmpp-dev +cp -r doc/html doc.qxmpp.org/qxmpp-dev + +git -C doc.qxmpp.org add . +git -C doc.qxmpp.org commit -m "Add documentation for QXmpp master" +git -C doc.qxmpp.org push + |
