huggingface_hub
62b8e199 - [CLI] Install & refresh the hf-cli skill (installer, update, hints) (#4608)

Commit
65 days ago
[CLI] Install & refresh the hf-cli skill (installer, update, hints) (#4608) * [CLI] Install and refresh the hf-cli skill from installer, update and hints - installer: opt-in `--include-skills` / `-IncludeSkills` runs `hf skills add hf-cli -g --claude` - `hf update`: refreshes the globally installed hf-cli skill (subprocess, new code on disk) - `hf <anything>`: suggests `hf skills add`/`hf skills update` at most once a day, never auto-installs Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * [CLI] Drop the removal disclaimer from the installer skill step Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * [CLI] Move skills directories to the global constants Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * [CI] Check the installers with --include-skills Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * [CLI] Clarify skill install/update wording in docs Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * Update docs/source/en/guides/cli.md * [CLI] Make the installer skill install opt-out (--exclude-skill) Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * [CLI] Drop the hf-cli skill from installer uninstall instructions Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * [CLI] Don't reinstall the hf-cli skill on `hf update` if opted out `hf update` re-runs the standalone installer, which now installs the skill by default. Check whether the skill is installed globally first and pass --exclude-skill / -ExcludeSkill when it isn't, so an opt-out is not silently undone. Also fixes flag passing for the PowerShell installer: `iwr ... | iex -Flag` cannot take parameters, use a scriptblock instead. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * [CLI] Skip the daily skill hint on `hf update` `hf update` handles the `hf-cli` skill itself, so the startup hint was either redundant (same `hf skills add` suggestion) or contradictory (suggesting a manual update right before doing it). Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * [CLI] Address review: symlink fallback on Windows, skip skill hint on dev/rc - `hf skills add --claude` falls back to a copy when symlinks aren't available (Windows without Developer Mode / admin rights). `hf skills update` walks both roots, so the copy stays in sync. - The daily 'skill is not installed' hint is skipped on pre-release / dev versions, same rule as the PyPI update check. * [CLI] Drop the two extra skill tests added in the previous commit Keeps only the necessary change to `test_hints_to_add_when_not_installed`: it must pin `__version__` to a stable value, otherwise the dev version now short-circuits the hint. * Update src/huggingface_hub/cli/skills.py --------- Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com> Co-authored-by: Celina Hanouti <hanouticelina@gmail.com>
Author
Parents
Loading