-
-
Notifications
You must be signed in to change notification settings - Fork 4.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Upload the changes to the generated docs to GitHub artifacts
Building the docs often takes too long locally, so this allows pull request submitters to build on GitHub, download the changes and incorporate the changes to the generated docs in a commit, then update their pull request with the generated docs commit. Also check that the changes to the prebuilt docs are committed, except for docs that change for every single rebuild.
- Loading branch information
Showing
2 changed files
with
24 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -51,6 +51,29 @@ jobs: | |
run: | | ||
python setup.py build_ext --inplace | ||
make -C docs/src clean html | ||
- name: Check changes to prebuilt docs | ||
run: | | ||
git config user.email "[email protected]" | ||
git config user.name "Gensim Docs Build" | ||
if ! git diff --quiet @ ; then | ||
git add . | ||
branch="$GITHUB_HEAD_REF ($GITHUB_REF_NAME)" | ||
git commit -m "Import rebuilt documentation for branch $branch" | ||
git format-patch @^ | ||
git bundle create prebuilt-docs-changes.bundle @^...@ | ||
git reset --mixed @^ | ||
git diff --exit-code --stat @ | ||
fi | ||
- name: Upload prebuilt docs changes | ||
if: always() | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: prebuilt-docs-changes | ||
path: | | ||
*.patch | ||
*.bundle | ||
# | ||
# FIXME: do we want to store the built documentation somewhere, or is | ||
# knowing that the docs built successfully enough? | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -75,6 +75,7 @@ data | |
*.inv | ||
*.js | ||
docs/_images/ | ||
docs/_downloads/ | ||
|
||
# | ||
# Generated by Cython | ||
|