Skip to content

Commit

Permalink
fix(ci): Fix docs version
Browse files Browse the repository at this point in the history
I am also removing one of the unused Github actions that we implemented before dependabot, which has now been completely replaced by dependabot.
  • Loading branch information
chriswmackey committed Jan 25, 2021
1 parent f3be47a commit 2098927
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 54 deletions.
20 changes: 9 additions & 11 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,24 +54,24 @@ jobs:
- name: install semantic-release
run:
npm install @semantic-release/exec
- name: generate docs for assets deployment
run: |
python docs.py $(echo $VERSION | sed 's/v//')
env:
VERSION: ${{ github.event.client_payload.version }}
- name: run semantic release
run:
id: new_release
run: |
nextRelease="`npx semantic-release --dryRun | grep -oP 'Published release \K.*? ' || true`"
npx semantic-release
echo "::set-output name=tag::$nextRelease"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
PYPI_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
PYPI_USERNAME: ${{ secrets.PYPI_USERNAME }}
outputs:
tag: ${{ steps.new_release.outputs.tag }}

docs:
name: Generate docs
runs-on: ubuntu-latest
needs: test
if: github.ref == 'refs/heads/master' && github.repository_owner == 'ladybug-tools'
needs: deploy
if: ${{ github.ref == 'refs/heads/master' && github.repository_owner == 'ladybug-tools' && contains(needs.deploy.outputs.tag, '.') }}
steps:
- uses: actions/checkout@v2
- name: set up Python
Expand All @@ -91,10 +91,8 @@ jobs:
pip install -r dev-requirements.txt
- name: generate docs
run: |
python docs.py $(echo $VERSION | sed 's/v//')
python docs.py --version ${{needs.deploy.outputs.tag}}
redoc-cli bundle ./docs/model_redoc.json -o ./docs/model.html
env:
VERSION: ${{ github.event.client_payload.version }}
- name: deploy to github pages
uses: peaceiris/actions-gh-pages@v3
Expand Down
41 changes: 0 additions & 41 deletions .github/workflows/honeybee-schema-release.yaml

This file was deleted.

2 changes: 0 additions & 2 deletions docs.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@

args = parser.parse_args()

VERSION = None

if args.version:
VERSION = args.version.replace('v', '')
else:
Expand Down

0 comments on commit 2098927

Please sign in to comment.