ArielJoe commited on
Commit
5a00eb2
·
1 Parent(s): 713c68e

fix: deploy Space via direct git push

Browse files
.github/workflows/deploy-hf-space.yml CHANGED
@@ -31,11 +31,12 @@ jobs:
31
  steps:
32
  - name: Checkout
33
  uses: actions/checkout@v4
34
-
35
- - name: Sync to Hugging Face Space
36
- uses: huggingface/hub-sync@v0.1.0
37
  with:
38
- github_repo_id: ${{ github.repository }}
39
- huggingface_repo_id: ArielJoe/Prompt-Builder
40
- hf_token: ${{ secrets.HF_TOKEN }}
41
- space_sdk: docker
 
 
 
 
 
31
  steps:
32
  - name: Checkout
33
  uses: actions/checkout@v4
 
 
 
34
  with:
35
+ fetch-depth: 0
36
+
37
+ - name: Push to Hugging Face Space
38
+ env:
39
+ HF_TOKEN: ${{ secrets.HF_TOKEN }}
40
+ run: |
41
+ git remote add hf-space "https://ArielJoe:${HF_TOKEN}@huggingface.co/spaces/ArielJoe/Prompt-Builder"
42
+ git push --force hf-space HEAD:main
README.md CHANGED
@@ -208,9 +208,11 @@ https://huggingface.co/spaces/ArielJoe/Prompt-Builder
208
 
209
  ### Auto Deploy Dari GitHub
210
 
211
- Workflow `.github/workflows/deploy-hf-space.yml` akan menyinkronkan repo GitHub
212
- ke Hugging Face Space setiap ada push ke branch `main` yang mengubah file
213
- pipeline, frontend, resource lexicon, Dockerfile, atau dependency.
 
 
214
 
215
  Setup satu kali:
216
 
 
208
 
209
  ### Auto Deploy Dari GitHub
210
 
211
+ Workflow `.github/workflows/deploy-hf-space.yml` akan push repo GitHub langsung
212
+ ke remote Hugging Face Space setiap ada push ke branch `main` yang mengubah file
213
+ pipeline, frontend, resource lexicon, Dockerfile, atau dependency. Workflow ini
214
+ tidak memakai endpoint create repo, sehingga lebih stabil untuk Space yang sudah
215
+ ada.
216
 
217
  Setup satu kali:
218