-
Notifications
You must be signed in to change notification settings - Fork 37
Add --tag option to download command #249
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
base: master
Are you sure you want to change the base?
Add --tag option to download command #249
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR adds tag filtering capability to the cloudsmith download command, enabling users to filter packages by tags alongside existing filters (version, format, architecture, OS). The implementation treats various package metadata fields as "tags" beyond just the explicit tags field.
Key Changes:
- Added
--tagoption to the download command with support for filtering by actual tags, format, architecture, distribution, and components - Enhanced package resolution logic with the new
_matches_tag_filter()helper function - Updated documentation with comprehensive download command examples
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 5 comments.
| File | Description |
|---|---|
| cloudsmith_cli/core/download.py | Added _matches_tag_filter() function and integrated tag filtering into resolve_package() |
| cloudsmith_cli/cli/commands/download.py | Added --tag CLI option and updated command documentation with tag filtering example |
| cloudsmith_cli/core/tests/test_download.py | Added unit test covering tag filtering for actual tags, format, architecture, and distro fields |
| README.md | Added download command to features list and created new "Downloading Packages" section with examples |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
b5cf8ac to
628c873
Compare
Summary
This PR adds tag filtering capability to the
cloudsmith downloadcommand and updates the README with comprehensive download command documentation.Changes Made
🚀 New Feature: --tag Option
--tagoption tocloudsmith downloadcommand for filtering packages by tagsresolve_package()function to support tag filtering across multiple metadata fields:📚 Documentation Updates
downloadcommand to README features list--tagfeatureUsage Examples
Testing
test_resolve_package_with_tag_filtervalidates tag filteringBreaking Changes
None - this is a backward-compatible feature addition.