Publish Documentation #913
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Publish Documentation | |
on: | |
push: | |
branches: ['*'] | |
schedule: | |
- cron: 0 3 * * * | |
workflow_dispatch: | |
jobs: | |
deploy: | |
runs-on: ubuntu-20.04 | |
steps: | |
- name: Install Doxygen and Graphviz | |
run: sudo apt-get install -y doxygen graphviz | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Clone Lean | |
run: git clone --depth 1 https://github.com/QuantConnect/Lean.git | |
- name: Generate Documentation | |
run: | | |
cp Doxyfile MAIN_PAGE.md ./custom-styles/style.css ./Lean | |
cd Lean | |
doxygen | |
cd .. | |
cp ./images/*.png ./_docs/ | |
cp ./images/*.svg ./_docs/ | |
cp ./custom-styles/*.css ./_docs/ | |
mv -f ./_docs/search.css ./_docs/search/ | |
mv -f ./_docs/close.png ./_docs/search/ | |
mv -f ./_docs/mag_sel.png ./_docs/search/ | |
rm -r Lean | |
- name: Delete Current "published" Branch | |
run: |- | |
git config --global user.email "[email protected]" | |
git config --global user.name "GitHub Actions" | |
git push origin --delete published | |
- name: Commit and Push | |
run: |- | |
git checkout -b published | |
git add -A | |
git commit --allow-empty -m "Updates Documentation" | |
git push origin published -f |