Setup github project so that after any change to master branch doxygen documentation is generated and pushed to gh-pages by Travis CI
- Add clean
gh-pagesbranch to your repository
git checkout --orphan gh-pages
git rm -rf .
echo "my gh-pages branch" > README.md
git add .
git commit -a -m "clean gh-pages branch"
git push origin gh-pages- Add Doxyfile to
masterbranch of your repository - Sign up for Travis CI and enable your project
- Generate personal access tokens with
public_reposcope - Add this token in Travis CI ->
Your Project->Settings->Environment VariablesasGH_REPO_TOKEN - Add
.travis.ymltomasterbranch of your repository:
sudo: false
branches:
only:
- master
addons:
apt:
packages:
- doxygen
script:
- doxygen Doxyfile
deploy:
provider: pages
skip_cleanup: true
local_dir: docs/html
github_token: $GH_REPO_TOKEN
on:
branch: masterTroubleshoot if needed watching Travis CI output for your project.
Your documentation will be available at:
https://[your github user].github.io/[your github project]/
Working example / documentation
Very usefull and clear article!
Thank you!