-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Unexport system commands #6305
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
Unexport system commands #6305
Conversation
This patch deprecates exported system commands and moves the implementation details to an unexported function. Commands that are affected include: - system.NewVersionCommand - system.NewInfoCommand - system.NewSystemCommand - system.NewEventsCommand - system.NewInspectCommand Signed-off-by: Alano Terblanche <[email protected]>
53ceedd to
cfb8cb9
Compare
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 deprecates exported system command constructors in the Docker CLI by moving them to unexported implementations while maintaining backward compatibility through wrapper functions.
Key changes:
- Adds deprecation warnings to exported command constructor functions
- Creates new unexported command constructors with the actual implementation
- Updates internal usage to use the new unexported functions
Reviewed Changes
Copilot reviewed 10 out of 10 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| cli/command/system/version.go | Deprecates NewVersionCommand and adds newVersionCommand with implementation |
| cli/command/system/info.go | Deprecates NewInfoCommand and adds newInfoCommand with implementation |
| cli/command/system/events.go | Deprecates NewEventsCommand and adds newEventsCommand with implementation |
| cli/command/system/inspect.go | Deprecates NewInspectCommand and adds newInspectCommand with implementation |
| cli/command/system/cmd.go | Deprecates NewSystemCommand and adds newSystemCommand with implementation |
| cli/command/commands/commands.go | Adds nolint directives for deprecated function usage |
| cli/command/system/*_test.go | Updates test files to use new unexported command constructors |
| cli/command/system/completion_test.go | Updates completion test to use unexported function |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
You can also share your feedback on Copilot code review for a chance to win a $100 gift card. Take the survey.
Codecov Report❌ Patch coverage is 📢 Thoughts on this report? Let us know! |
thaJeztah
left a comment
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.
LGTM
This patch deprecates exported system commands and moves the implementation details to an unexported function.
Commands that are affected include:
- What I did
- How I did it
- How to verify it
- Human readable description for the release notes
- A picture of a cute animal (not mandatory but encouraged)