Skip to content

add windows HKEY support#35

Merged
tommyjcarpenter merged 3 commits into
mainfrom
schema
May 29, 2026
Merged

add windows HKEY support#35
tommyjcarpenter merged 3 commits into
mainfrom
schema

Conversation

@tommyjcarpenter

@tommyjcarpenter tommyjcarpenter commented May 29, 2026

Copy link
Copy Markdown
Owner

Add a new optional shell_menu_cleanup section to the config schema for declaring Windows Explorer right-click (shell) menu cleanup state. Windows-only, like file_associations; it captures the three distinct places a shell verb can hide so they can be cleaned up declaratively rather than by hand.

The section nests under a windows key and exposes three arrays, one per mechanism:

  • com_handlers_blocked: CLSIDs written as empty REG_SZ value names under HKLM\Software\Microsoft\Windows\CurrentVersion\Shell Extensions\Blocked.
  • static_verbs_disabled: registry verb keys that get an empty LegacyDisable REG_SZ, hiding the verb without deleting the key; treated as already-done when the key is absent on the current machine.
  • appx_packages_removed: wildcard package-name patterns fed to Get-AppxPackage | Remove-AppxPackage for MSIX-packaged shell extensions.

Each entry requires only its identifying field (clsid / path / name_pattern); an optional name is carried for log readability. Every level sets additionalProperties: false, so a typo'd array key or OS section fails validation rather than being silently skipped, consistent with the rest of the schema.

Changes:

  • bootstrap/schema.py: new shell_menu_cleanup top-level section plus three definitions (shell_menu_com_handler, shell_menu_static_verb, shell_menu_appx_package).
  • tests/test_schema.py: new TestShellMenuCleanupSchema with positive cases (full and required-only) and negative cases (missing required field, unknown property, unknown OS section).

Signed-off-by: Tommy Carpenter <9419125+tommyjcarpenter@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Adds a new optional configuration section to the JSON schema for describing Windows Explorer right‑click (shell) menu cleanup actions, including registry-based verb disabling and uninstalling AppX/MSIX shell extensions.

Changes:

  • Introduces a new top-level shell_menu_cleanup section (Windows-only) in the schema.
  • Adds three new schema definitions to validate COM handler CLSIDs, static verb registry paths, and AppX package name patterns.

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

Comment thread bootstrap/schema.py
Comment thread bootstrap/schema.py

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

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 2 out of 2 changed files in this pull request and generated no new comments.

@tommyjcarpenter tommyjcarpenter merged commit 1fda610 into main May 29, 2026
6 checks passed
@tommyjcarpenter tommyjcarpenter deleted the schema branch May 29, 2026 15:20
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