Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix repo-files CLI example #2428

Merged
merged 1 commit into from
Jul 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/source/en/guides/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -451,7 +451,7 @@ Files correctly deleted from repo. Commit: https://huggingface.co/Wauplin/my-coo

Use Unix-style wildcards to delete sets of files:
```bash
>>> huggingface-cli repo-files Wauplin/my-cool-model delete *.txt folder/*.bin
>>> huggingface-cli repo-files Wauplin/my-cool-model delete "*.txt" "folder/*.bin"
Files correctly deleted from repo. Commit: https://huggingface.co/Wauplin/my-cool-mo...
```

Expand Down
4 changes: 2 additions & 2 deletions src/huggingface_hub/commands/repo_files.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

Usage:
# delete all
huggingface-cli repo-files <repo_id> delete *
huggingface-cli repo-files <repo_id> delete "*"

# delete single file
huggingface-cli repo-files <repo_id> delete file.txt
Expand All @@ -28,7 +28,7 @@
huggingface-cli repo-files <repo_id> delete file.txt folder/ file2.txt

# delete multiple patterns
huggingface-cli repo-files <repo_id> delete file.txt *.json folder/*.parquet
huggingface-cli repo-files <repo_id> delete file.txt "*.json" "folder/*.parquet"

# delete from different revision / repo-type
huggingface-cli repo-files <repo_id> delete file.txt --revision=refs/pr/1 --repo-type=dataset
Expand Down
Loading