-
-
Notifications
You must be signed in to change notification settings - Fork 3k
ksud: refine boot patch, add --out-name arg to boot-patch and boot-restore command
#2982
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
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 refactors the boot patching and restore functionality by introducing dedicated argument structs (BootPatchArgs and BootRestoreArgs) to replace individual function parameters, and adds support for customizing the output file name via the new out_name parameter.
- Introduced
BootPatchArgsandBootRestoreArgsstructs to encapsulate CLI arguments - Added
out_nameparameter to allow custom output file naming for both patch and restore operations - Improved code by replacing
.to_str().unwrap()with.display()for safer path formatting
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| userspace/ksud/src/boot_patch.rs | Defines BootPatchArgs and BootRestoreArgs structs with clap annotations, refactors patch() and restore() functions to accept struct arguments, adds out_name field support, and improves path display formatting |
| userspace/ksud/src/cli.rs | Replaces inline CLI argument definitions with references to new BootPatchArgs and BootRestoreArgs structs, simplifies command handling by passing structs directly |
| userspace/ksud/src/utils.rs | Updates uninstall() function to construct BootRestoreArgs struct when calling boot_patch::restore(), adds import for BootRestoreArgs |
💡 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 3 out of 3 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 3 out of 3 changed files in this pull request and generated no new comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
--out-name arg to boot-patch and boot-restore command
…restore command (tiann#2982) Signed-off-by: fc5b87cf <[email protected]>
No description provided.