Skip to content

Commit

Permalink
Generate zero-dependency doc in its own subdirectory.
Browse files Browse the repository at this point in the history
Use GH Action to publish contents of that subdirectory to /docs in external repo.
  • Loading branch information
mgdaily committed Jun 10, 2021
1 parent a8ad574 commit 211f900
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
1 change: 1 addition & 0 deletions .github/workflows/docs-gh-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ jobs:
with:
personal_token: ${{ secrets.PERSONAL_TOKEN }}
external_repository: mgdaily/mgdaily-test-github-pages.github.io
publish_dir: docs
destination_dir: docs
publish_branch: main
keep_files: true
Expand Down
5 changes: 3 additions & 2 deletions make-docs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ python manage.py generateschema_mocked --file downtime.yaml

# Bundle docs into zero-dependency HTML file
npx redoc-cli bundle downtime.yaml && \
mv redoc-static.html downtime.html && \
mkdir docs && \
mv redoc-static.html docs/downtime.html && \
echo "Changed name from redoc-static.html to index.html" && \
echo -e "\nDone!"
echo -e "\nDone!"

0 comments on commit 211f900

Please sign in to comment.