Skip to content

Commit

Permalink
win: improve Microsoft Edge associations removal
Browse files Browse the repository at this point in the history
This commit refactors the removal of Edge associations to use shared
registry functions, streamlining all registry operations. It also
enhances the logic for removing associations with several improvements.

Key changes:

- Create separate shared functions for each association modification.
- Prefer modifying real keys over `HKCR` keys for reliability
- Add more documentation for affected scripts and new shared functions
- Replace loops with explicit calls for clarity and maintainability
- Extend handling of registry keys to both HKCU/HKLM hives
- Add missing association removals
- Add OS checks to apply only on correct Windows versions
- Split scripts for more granularity and maintainability
- Handle permission errors for user choice keys on recent Windows

Other supporting changes:

- Add `REG_DWORD` revert support for `DeleteRegistryKey`
- Add `grantPermissions` support for `DeleteRegistryValue`
- Add delete data only if undesired for `DeleteRegistryValue`
- Shorten generated code in `DeleteRegistryValue` to prevent reaching
  `cmd.exe` limits
- Add more Windows versions for script constraints
  • Loading branch information
undergroundwires committed Aug 8, 2024
1 parent e8add5e commit c2f4b68
Showing 1 changed file with 1,677 additions and 384 deletions.
Loading

0 comments on commit c2f4b68

Please sign in to comment.