Skip to content

Commit b058e20

Browse files
committed
Fix docs workflow (maybe)
1 parent 6139b84 commit b058e20

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

.github/workflows/docs.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,14 +25,16 @@ jobs:
2525
- name: Install
2626
run: |
2727
python -m pip install --no-cache-dir -r requirements-dev.txt
28-
- name: Get branch/tag name
29-
id: get-branch
30-
uses: ypicard/get-branch-name-github-action@v1
3128
- name: Generate docs
3229
if: ${{ success() }}
3330
run: |
3431
invoke docs
35-
mkdir -p deploy/compas_fab/${{ steps.get-branch.outputs.tag }} && mv -T dist/docs deploy/compas_fab/${{ steps.get-branch.outputs.tag }}/
32+
BRANCH_OR_TAG=${GITHUB_REF##*/}
33+
if [ $BRANCH_OR_TAG = "master" ]; then
34+
BRANCH_OR_TAG="latest"
35+
fi;
36+
mkdir -p deploy/compas_fab/$BRANCH_OR_TAG && mv -T dist/docs deploy/compas_fab/$BRANCH_OR_TAG/
37+
echo "Docs will be deployed to https://gramaziokohler.github.io/compas_fab/$BRANCH_OR_TAG"
3638
- name: Deploy docs
3739
if: success()
3840
uses: crazy-max/ghaction-github-pages@v2

0 commit comments

Comments
 (0)