Skip to content

Add the CLI option to kill the locker processes.#1

Merged
wangfu91 merged 6 commits into
masterfrom
kill-locker-processes
May 19, 2025
Merged

Add the CLI option to kill the locker processes.#1
wangfu91 merged 6 commits into
masterfrom
kill-locker-processes

Conversation

@wangfu91
Copy link
Copy Markdown
Owner

No description provided.

@wangfu91 wangfu91 requested a review from Copilot May 19, 2025 01:32
Copy link
Copy Markdown

Copilot AI left a 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 a new CLI option to kill processes locking a specified file by introducing a confirmation prompt and process termination logic. Key changes include:

  • Reordering and updating imports and API calls for process-related functions.
  • Adjustment of the _pid_to_user function return order for correct user/domain mapping.
  • Addition of the kill_process_by_pid function along with new CLI option processing and confirmation workflow in the main function.

Reviewed Changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/process_ext.rs Update API call order, adjust user/domain return values, and add process termination support.
src/path_ext.rs Reordered imports; no logic changes.
src/main.rs Added new CLI option for killing processes with user confirmation and process termination logic.
src/handle_ext.rs Minor reordering of imports.
Cargo.toml Added dependency on colored for enhanced CLI output.
Comments suppressed due to low confidence (1)

src/process_ext.rs:266

  • The function name 'get_moudle_name' appears to contain a typo; consider renaming it to 'get_module_name' for improved clarity and consistency.
get_moudle_name(&safe_process_handle, None)

@wangfu91 wangfu91 merged commit 7f91019 into master May 19, 2025
1 check passed
@wangfu91 wangfu91 deleted the kill-locker-processes branch May 19, 2025 01:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants