Skip to content

Commit

Permalink
update workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
Alleria1809 committed Jun 28, 2024
1 parent c7d8639 commit 69da375
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 19 deletions.
25 changes: 7 additions & 18 deletions .github/workflows/documentation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,6 @@ on:
- xiaoyi_doc
workflow_dispatch:

permissions: # This sets permissions for all jobs
contents: write
actions: read

jobs:
docs:
runs-on: ubuntu-latest
Expand All @@ -18,22 +14,15 @@ jobs:
- uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: List docs directory
run: ls -l ./docs
- name: Display requirements.txt
run: cat ./docs/requirements.txt

- name: Install dependencies
run: |
pip install -r ./docs/requirements.txt
pip freeze
pip freeze # Display installed packages for debugging
- name: Sphinx build
run: |
sphinx-build -b html docs/source/ docs/build/
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/xiaoyi_doc' }}
with:
publish_branch: gh-pages
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./docs/build/
force_orphan: true
# Building the documentation in the specified directory
sphinx-build -b html docs/source/ ./docs/build/
# Optionally, list output files for debugging
ls -l ./docs/build/
3 changes: 2 additions & 1 deletion docs/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,5 @@ nbconvert==7.16.4
PyYAML
readthedocs-sphinx-search==0.3.2
numpy
tqdm
tqdm
tiktoken

0 comments on commit 69da375

Please sign in to comment.