Skip to content

Commit 7403747

Browse files
committed
updated hf_deploy_workflow
1 parent 5fc425a commit 7403747

File tree

3 files changed

+19
-14
lines changed

3 files changed

+19
-14
lines changed

.gitattributes

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
*.png
2-
*.gif
1+
*.gif filter=lfs diff=lfs merge=lfs -text
2+
*.png filter=lfs diff=lfs merge=lfs -text

.github/workflows/hf_space_push.yml

Lines changed: 17 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -25,21 +25,28 @@ jobs:
2525
rsync -av codetide/agents/tide/ui/.chainlit/ examples/hf_demo_space/.chainlit/
2626
rsync -av codetide/agents/tide/ui/public/ examples/hf_demo_space/public/
2727
cp codetide/agents/tide/ui/chainlit.md examples/hf_demo_space/
28-
cp codetide/agents/tide/ui/chainlit.md examples/hf_demo_space/
2928
cp .gitattributes examples/hf_demo_space
3029
cd examples/hf_demo_space
30+
3131
git lfs install
3232
git init --initial-branch=main
3333
git config user.name "github-actions[bot]"
3434
git config user.email "github-actions[bot]@users.noreply.github.com"
3535
git remote add origin https://McLoviniTtt:$HF_TOKEN@huggingface.co/spaces/McLoviniTtt/AgentTideDemo
36+
37+
# Set up LFS tracking for your binary files
38+
git lfs track "*.gif"
39+
git lfs track "*.png"
40+
git lfs track "public/*.gif"
41+
git lfs track "public/*.png"
42+
git lfs track "public/avatars/*.png"
43+
44+
# Add .gitattributes first (this tells git which files to track with LFS)
45+
git add .gitattributes
46+
47+
# Now add all files - the binary ones will be handled by LFS
3648
git add .
37-
git commit -m "Deploy Agent Tide Demo to HF Space"
38-
git filter-branch --force --index-filter "
39-
git rm --cached --ignore-unmatch public/agent-tide-demo.gif
40-
git rm --cached --ignore-unmatch public/avatars/agent_tide.png
41-
git rm --cached --ignore-unmatch public/codetide-banner.png
42-
git rm --cached --ignore-unmatch public/logo_dark.png
43-
git rm --cached --ignore-unmatch public/logo_light.png
44-
" HEAD
45-
git push --force --all
49+
git commit -m "Deploy Agent Tide Demo to HF Space with LFS"
50+
51+
# Push everything (no filter-branch needed since LFS handles the binary files)
52+
git push --force origin main

gitattributes

Lines changed: 0 additions & 2 deletions
This file was deleted.

0 commit comments

Comments
 (0)