Fix website again again (#9061)

* run the website workflows

* run the website workflows
This commit is contained in:
pngwn 2024-08-07 20:20:04 +01:00 committed by GitHub
parent 3b50d69872
commit ac6f4d9e8e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 5 additions and 4 deletions

View File

@ -84,12 +84,12 @@ jobs:
# production
- name: Pull Vercel Environment Information
if: needs.changes.outputs.source_repo == 'gradio-app/gradio' && needs.changes.outputs.source_branch == 'main'
if: needs.changes.outputs.source_repo == 'gradio-app/gradio' && endsWith(needs.changes.outputs.source_branch, 'main')
shell: bash
run: vercel pull --yes --environment=production --token=${{ secrets.VERCEL_DEPLOY_TOKEN }} --cwd js/_website
- name: Deploy Project Artifacts to Vercel
if: needs.changes.outputs.source_repo == 'gradio-app/gradio' && needs.changes.outputs.source_branch == 'main'
if: needs.changes.outputs.source_repo == 'gradio-app/gradio' && endsWith(needs.changes.outputs.source_branch, 'main')
shell: bash
run: echo "VERCEL_URL=$(vercel deploy --prebuilt --prod --token=${{ secrets.VERCEL_DEPLOY_TOKEN }})" --cwd js/_website >> $GITHUB_ENV

View File

@ -30,6 +30,7 @@ jobs:
should_run: ${{ steps.changes.outputs.should_run }}
sha: ${{ steps.changes.outputs.sha }}
gradio_version: ${{ steps.changes.outputs.gradio_version }}
source_branch: ${{ steps.changes.outputs.source_branch }}
steps:
- uses: actions/checkout@v4
- uses: "gradio-app/gradio/.github/actions/changes@main"
@ -44,7 +45,7 @@ jobs:
name: "docs-build"
runs-on: ubuntu-22.04
needs: changes
if: needs.changes.outputs.should_run == 'true' || (github.ref_name == 'main' && github.repository == 'gradio-app/gradio')
if: needs.changes.outputs.should_run == 'true' || (endsWith(needs.changes.outputs.source_branch, 'main') && github.repository == 'gradio-app/gradio')
steps:
- uses: actions/checkout@v4
- name: install dependencies

View File

@ -53,7 +53,7 @@ jobs:
message: website~pending~null
deploy:
environment: deploy_website
name: "website-deploy"
name: "docs-deploy"
runs-on: ubuntu-latest
needs: changes
if: needs.changes.outputs.should_run == 'true' || github.event.workflow_run.event == 'push'