Skip to content

Commit cea09b9

Browse files
committed
fix: configuration of the sphinx-action
1 parent 69af687 commit cea09b9

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

.github/workflows/builddocs.yml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,20 +24,19 @@ jobs:
2424
run: |
2525
if [[ "$GITHUB_REF" == refs/tags/* ]]; then
2626
CURBRANCH=${GITHUB_REF##*/}
27+
elif [[ "$GITHUB_REF" == refs/pull/* ]]; then
28+
CURBRANCH=${GITHUB_REF%/*}
29+
CURBRANCH=${CURBRANCH##*/}
2730
elif [[ "$GITHUB_REF" == refs/heads/* ]]; then
2831
CURBRANCH=${GITHUB_REF##*/}
2932
fi
3033
31-
if [ "$CURBRANCH" == "" ] && [[ "$GITHUB_BASE_REF" == refs/heads/* ]]; then
32-
CURBRANCH=${GITHUB_BASE_REF##*/}
33-
fi
34-
3534
# Remove forward slashes
3635
CURBRANCH=$( echo $CURBRANCH | sed 's+/+_+g' )
3736
echo "Building branch/tag ${CURBRANCH:-<unkwown>}, from git ref <$GITHUB_REF>"
3837
echo "CURBRANCH=${CURBRANCH}" >> ${GITHUB_ENV}
3938
4039
- uses: ammaraskar/sphinx-action@master
4140
with:
42-
docs-folder: "docs/"
43-
build-command: make -C docs/ SPHINXOPTS="-W" BUILDDIR="$HOME/docs" CURBRANCH="${CURBRANCH:-html}" html
41+
docs-folder: "."
42+
build-command: make -C docs/ PYTHONPATH="${GITHUB_WORKSPACE}" SPHINXOPTS="-W" BUILDDIR="$HOME/docs" CURBRANCH="${CURBRANCH:-html}" html

0 commit comments

Comments
 (0)