textparser-backend / push_dockerfile.py
whoisscaramouchee's picture
Claude Opus 4.6 (1M context)
Sync latest backend code
b6a11c6
Raw History Blame Contribute Delete
505 Bytes
from huggingface_hub import HfApi, CommitOperationAdd
TOKEN = "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"
REPO = "whoisscaramouchee/textparser-backend"
api = HfApi(token=TOKEN)
with open("C:/Projects/.ut/hf-deploy/Dockerfile", "rb") as f:
content = f.read()
print(content.decode())
api.create_commit(
repo_id=REPO,
repo_type="space",
operations=[CommitOperationAdd(path_in_repo="Dockerfile", path_or_fileobj=content)],
commit_message="Fix: port 7860 for HF Spaces"
)
print("\nDone!")