Skip to content

Add quarantine clean mode and custom keeplists with UI selection and enhancements#7

Merged
Therosin merged 10 commits intomainfrom
develop
Mar 1, 2026
Merged

Add quarantine clean mode and custom keeplists with UI selection and enhancements#7
Therosin merged 10 commits intomainfrom
develop

Conversation

@Therosin
Copy link
Member

@Therosin Therosin commented Mar 1, 2026

This pull request introduces support for keeplist prefixes in ModCleaner, allowing users to maintain and switch between multiple keeplist files for different mod setups. The README is updated to explain the new prefix system, and the codebase is refactored to consistently use the active keeplist file based on the selected prefix. Additionally, a safer "quarantine" clean mode is implemented, which moves removable files into a dedicated quarantine directory instead of permanently deleting them. Comprehensive tests are added to validate the new features and ensure correct behavior.

Keeplist Prefix Support

  • Added a system for keeplist prefixes, allowing users to switch between multiple keeplist files (e.g., #vanilla-keeplist.txt) via a hidden UI shortcut, and updated all relevant logic to resolve and use the active keeplist name throughout the codebase (logic.ts, README.md) [1] [2] F37caa32L49R49, [3] [4] [5] [6].

Quarantine Clean Mode

  • Introduced a "quarantine" mode for cleaning, which moves removable files into a .modcleaner_quarantine/<timestamp>/ directory, providing a manual recovery path and reducing risk of accidental data loss (logic.ts, README.md) [1] [2] [3].

README Documentation Updates

  • Expanded and clarified documentation to cover keeplist prefixes, quarantine mode, and updated terminology to refer to the "active keeplist" rather than just #keeplist.txt (README.md) [1] [2] [3] [4] [5] [6] [7].

Robust Handling of Keeplist Files

  • Improved logic to ensure all keeplist files (default and prefixed) are protected from removal, and error messages accurately reference the active keeplist file in all scenarios (logic.ts, logic_test.ts) [1] [2] [3].

Test Coverage Enhancements

  • Added thorough tests to verify prefix logic, protection of keeplist files, correct scan and clean behavior for both default and prefixed keeplists, and error handling for missing or empty keeplist files (logic_test.ts) [1] [2] [3].

Copilot AI review requested due to automatic review settings March 1, 2026 13:51
Copy link
Contributor

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 extends ModCleaner to support multiple keeplist files (via an optional prefix system) and adds a safer “quarantine” clean mode that moves removable files into a dedicated quarantine directory instead of permanently deleting them. It updates the UI and documentation to reflect “active keeplist” behavior and adds tests to validate the new modes and filename resolution.

Changes:

  • Add keeplist prefix support and consistently thread the active keeplist filename through scan/clean/generate flows.
  • Implement quarantine clean mode (.modcleaner_quarantine/<timestamp>/) and exclude quarantine contents from scans.
  • Expand tests and README documentation to cover the new behaviors and error reporting.

Reviewed changes

Copilot reviewed 4 out of 5 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
main.ts UI enhancements for active keeplist display, hidden prefix entry, and clean-mode selection; passes active keeplist + mode into logic.
logic.ts Adds quarantine mode, keeplist name resolution/plumbing, and traversal exclusion for the quarantine directory.
logic_test.ts Adds coverage for keeplist prefix behavior and quarantine mode correctness (layout, no data loss, exclusions).
README.md Documents active keeplist semantics, prefix system, and quarantine vs delete clean modes.
deno.lock Updates locked dependency versions/specifiers.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@Therosin
Copy link
Member Author

Therosin commented Mar 1, 2026

@codex review

Copy link
Contributor

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

Copilot reviewed 4 out of 5 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 0d32d44ea8

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@Therosin Therosin merged commit 1c7928b into main Mar 1, 2026
4 checks passed
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.

3 participants