Minor typo/bug fixes (#945) #180
This file contains hidden or 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: ActivitySim Branch Docs | |
| # This workflow is provided as a service for forks to build branch-specific documentation. | |
| on: | |
| - push | |
| - workflow_dispatch | |
| jobs: | |
| docbuild: | |
| if: "github.event_name == 'workflow_dispatch' || (contains(github.event.head_commit.message, '[makedocs]') && (github.repository_owner != 'ActivitySim') && (github.ref_name != 'develop'))" | |
| # develop branch docs are built at the end of the core test workflow, regardless of repository owner or commit message flags | |
| name: ubuntu-latest py3.10 | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| defaults: | |
| run: | |
| shell: bash -l {0} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 # get all tags, lets setuptools_scm do its thing | |
| - name: Setup Miniforge | |
| uses: conda-incubator/setup-miniconda@v2 | |
| with: | |
| miniforge-version: latest | |
| python-version: "3.10" | |
| activate-environment: docbuild | |
| auto-activate-base: false | |
| auto-update-conda: false | |
| - name: Set cache date for year and month | |
| run: echo "DATE=$(date +'%Y%m')" >> $GITHUB_ENV | |
| - uses: actions/cache@v3 | |
| with: | |
| path: /usr/share/miniconda3/envs/docbuild | |
| key: linux-64-conda-${{ hashFiles('conda-environments/docbuild.yml') }}-${{ env.DATE }}-${{ env.CACHE_NUMBER }} | |
| id: cache | |
| - name: Update environment | |
| run: conda env update --verbose -n docbuild -f conda-environments/docbuild.yml | |
| if: steps.cache.outputs.cache-hit != 'true' | |
| - name: Install activitysim | |
| run: | | |
| python -m pip install . | |
| - name: Conda checkup | |
| run: | | |
| conda info -a | |
| conda list | |
| echo REPOSITORY ${{ github.repository }} | |
| echo REF ${{ github.ref }} | |
| echo REF_NAME ${{ github.ref_name }} | |
| - name: Build the docs | |
| run: | | |
| cd docs | |
| make clean | |
| make html | |
| - name: Push to GitHub Pages | |
| uses: peaceiris/actions-gh-pages@v4 | |
| with: | |
| github_token: ${{ secrets.GITHUB_TOKEN }} | |
| # Token is created automatically by Github Actions, no other config needed | |
| publish_dir: ./docs/_build/html | |
| destination_dir: ${{ github.ref_name }} |