Spaces:
Build error
Build error
Mohammed Zaloom commited on
Update main.yml
Browse files12 unmodified lines131415161718192021222324252627282930313233343512 unmodified lineswith:fetch-depth: 0- name: Clear Git credentials cache# This clears any cached credentials that might interfere with token-based auth.run: |git config --global --unset credential.helper || true- name: Install Git LFSrun: git lfs install- name: Add remote using Access Tokenenv:HF: ${{ secrets.HF }}run: |# Remove remote if already exists (to avoid duplicate remotes)git remote remove space || true# Add remote with your username and access tokengit remote add space https://mozaloom:${{ secrets.HF }}@huggingface.co/spaces/mozaloom/demo# Print remote configuration for debugging (token will be masked)git remote -v- name: Push to Hub with Verbose Debugging12 unmodified lines131415161718192021222324252627282930313212 unmodified lineswith:fetch-depth: 0- name: Clear cached Git credentialsrun: git config --global --unset credential.helper || true- name: Install Git LFSrun: git lfs install- name: Add remote using URL-encoded Access Tokenenv:HF: ${{ secrets.HF }}run: |# URL-encode the token using PythonENCODED_TOKEN=$(python -c "import sys, urllib.parse; print(urllib.parse.quote(sys.argv[1].strip()))" "$HF")git remote remove space || truegit remote add space https://mozaloom:${ENCODED_TOKEN}@huggingface.co/spaces/mozaloom/demogit remote -v- name: Push to Hub with Verbose Debugging
.github/workflows/main.yml+6-9