Spaces:
Running
Running
name: Deploy | |
on: | |
push: | |
branches: | |
- main | |
permissions: | |
contents: write | |
id-token: write | |
jobs: | |
documentation: | |
name: update documentations on gitHub pages | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: 3.11 | |
- uses: actions/cache@v2 | |
with: | |
key: ${{ github.ref }} | |
path: .cache | |
- run: | | |
pip install --upgrade pip | |
pip install .[docs] | |
- run: mkdocs gh-deploy --force | |
sync-to-hub: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
lfs: true | |
- name: Push to hub | |
env: | |
HF_TOKEN: ${{ secrets.HF_TOKEN }} | |
run: git push https://HF_USERNAME:$HF_TOKEN@huggingface.co/spaces/wandb/guardrails-genie main |