| name: Deploy to Hugging Face Spaces |
|
|
| on: |
| push: |
| branches: |
| - main |
|
|
| jobs: |
| deploy: |
| runs-on: ubuntu-latest |
| steps: |
| - name: Checkout repository |
| uses: actions/checkout@v3 |
| with: |
| fetch-depth: 0 |
|
|
| - name: Deploy to Hugging Face Space |
| env: |
| HF_HUB_TOKEN: ${{ secrets.HF_TOKEN }} |
| run: | |
| git config --global credential.helper store |
| git config --global user.email "huggingface-ci@users.noreply.github.com" |
| git config --global user.name "Hugging Face CI" |
| git remote add hf https://oauth2:${HF_HUB_TOKEN}@huggingface.co/spaces/Rajhuggingface4253/backend-compressorPro |
| git push -f hf main |