Download .github/workflows/sync.yml from Anonymized1/Interacting-With-LLMs: direct link, hf CLI and curl.
- Browser
- Download file 1.2 kB
-
https://huggingface.co/spaces/Anonymized1/Interacting-With-LLMs/resolve/main/.github/workflows/sync.yml
- Command line
-
hf download hf://spaces/Anonymized1/Interacting-With-LLMs/.github/workflows/sync.yml
-
curl -L -o sync.yml https://huggingface.co/spaces/Anonymized1/Interacting-With-LLMs/resolve/main/.github/workflows/sync.yml
1.2 kB
| name: Sync with Original HF Space | |
| on: | |
| schedule: | |
| - cron: '0 0 * * *' # Runs once a day at midnight UTC. Change to '*/15 * * * *' for every 15 minutes. | |
| workflow_dispatch: # Allows you to trigger the sync manually. | |
| jobs: | |
| sync: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout Repository | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - name: Fetch and Push Changes | |
| run: | | |
| # Configure Git credentials | |
| git config --global user.name "Hugging Face Sync Bot" | |
| git config --global user.email "bot@huggingface.co" | |
| # Add the original HF space as a remote source | |
| git remote add original https://huggingface.co/spaces/michael2222222/Interacting-With-LLMs | |
| # Add your duplicate HF space as the destination destination | |
| git remote add duplicate https://USER:${{ secrets.HF_TOKEN }}@huggingface.co/spaces/Anonymized1/Interacting-With-LLMs | |
| # Fetch the latest code from the original space | |
| git fetch original main | |
| # Push the updates to your duplicate space | |
| git push duplicate original/main:main --force | |