Skip to content
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

Force remove microsoft edge regardless of region/country. #64

Open
wants to merge 12 commits into
base: master
Choose a base branch
from

Conversation

loadstring1
Copy link
Contributor

@loadstring1 loadstring1 commented May 31, 2024

Tested and works on my windows 11 home 22h2 it wiped microsoft edge out of my system. I used closed-source programs to help myself with writing this feature.

Please let me know if i should also consider force uninstalling edge webview and edge update because for now this is just edge uninstaller

fixes this issue: 38

- remove more registry keys
- fix Test-Path spam and Remove-Item spam with foreach loops
- attempt to uninstall edge with winget first then uninstall it forcefully
- add credits and update version number to 1.1
- Edge update is now uninstalled forcefully alongside with edge
@loadstring1
Copy link
Contributor Author

loadstring1 commented Jun 1, 2024

v 1.1
microsoft edge update is now removed alongside with microsoft edge
fixed Test-Path and Remove-Item spam. (aka made the script look cuter)

it doesn't uninstall edge webview because you can manually uninstall it so automatic script is not really needed for that also edge webview is required for roblox studio to work so its a big adventage for people who play roblox (like me)

:)

@loadstring1
Copy link
Contributor Author

@Raphire please review when you have time to do so thx

@loadstring1
Copy link
Contributor Author

one more thing if you are wondering how to test if it works correctly and you don't have edge installed

then download edge and install it from here or just install ms edge with winget: https://www.microsoft.com/en-us/edge/download?form=MA13FJ

unregister ms edge from task scheduler
remove ms edge services
- Fixed task names
- Removes leftover ms edge shortcut in User Pinned\TaskBar
- Force kill all edge processes without prompting user for permission to do so
- Fix PSScriptAnalyzer(PSAvoidCmdletAliases) (swap cd to Set-Location)
- Fix PSScriptAnalyzer(PSAvoidAssignmentToAutomaticVariable) (swap $args to $arguments)
- This commit makes it more future proof
- add comma
- remove mode 5 testing
@zoicware
Copy link

zoicware commented Jun 2, 2024

I have modified an existing script from @AveYo to completely uninstall edge (webview hard locked cant uninstall anymore)
OG Script: https://github.com/AveYo/fox/blob/main/Edge_Removal.bat)
My edited script (Notice making a folder and exe fixes it from being unable to be uninstalled):
EdgeRemove.zip

@loadstring1
Copy link
Contributor Author

I have modified an existing script from @AveYo to completely uninstall edge (webview hard locked cant uninstall anymore) OG Script: https://github.com/AveYo/fox/blob/main/Edge_Removal.bat) My edited script (Notice making a folder and exe fixes it from being unable to be uninstalled): EdgeRemove.zip

your script looks way more advanced than mine maybe make seperate pull request for that?

@zoicware
Copy link

zoicware commented Jun 4, 2024

I have modified an existing script from @AveYo to completely uninstall edge (webview hard locked cant uninstall anymore) OG Script: https://github.com/AveYo/fox/blob/main/Edge_Removal.bat) My edited script (Notice making a folder and exe fixes it from being unable to be uninstalled): EdgeRemove.zip

your script looks way more advanced than mine maybe make seperate pull request for that?

#66
went ahead and replaced onedrive removal as well

@loadstring1
Copy link
Contributor Author

loadstring1 commented Jun 4, 2024

#66 went ahead and replaced onedrive removal as well

onedrive actually uninstalls without refusing to do that so you don't have to force uninstall it

edit: thanks to your pull request i learned about -ErrorAction SilentlyContinue and i'll add this to my pull request too because why not

- silence task scheduler errors when task doesn't exist
@Raphire
Copy link
Owner

Raphire commented Jun 5, 2024

I will have a look at this soon. Although I'm not sure how I feel about manually removing everything related to edge like this. It can become a pain if anything related to registry or location of stored files changes in the future.

@loadstring1
Copy link
Contributor Author

loadstring1 commented Jun 5, 2024

I will have a look at this soon. Although I'm not sure how I feel about manually removing everything related to edge like this. It can become a pain if anything related to registry or location of stored files changes in the future.

You can't just only rely on registry to disable windows features (such as recall) because those features waste disk space and deleting them from C drive solves that issue

about Microsoft Edge:
A) It's piece of bloatware wasting around 700 MB of disk space
B) There is no way of removing microsoft edge with control panel or settings but you can still force kill all of its processes and delete it from Program Files x86 and auto start
C) uninstall.exe method got patched and it doesn't uninstall itself anymore you really need to forcefully uninstall it like that (aka it ignores anything that tries to uninstall msedge that way)

or finally just wait until microsoft actually allows you to uninstall msedge without refusing to do that (obviously they won't allow you to uninstall their "best browser" just because of this github repo)

What i learned is MSedge reinstalls itself by relying on edge update "service" booting on start-up in task scheduler and registry auto start so my pull request targets both microsoft edge and edge update so it doesn't reinstall itself

I still can't disagree this script looks pretty messy and it requires constant updating when microsoft moves their browser somewhere else (for example migration from program files x86 to program files you get what i mean)

Registry key removal is pretty messy and maybe i'll try fixing that mess

- remove msedge shortcut from user desktop
- remove msedge tasks regardless of randomly generated UUID from task scheduler
- silencing task scheduler errors is no longer needed
- fix registry mess
- check if edge is installed before trying to uninstall it with winget
@loadstring1
Copy link
Contributor Author

Registry key removal is pretty messy and maybe i'll try fixing that mess

  • registry mess fixed
  • merged with latest win11debloat master branch

@Raphire Raphire force-pushed the master branch 2 times, most recently from ec78713 to abff3f0 Compare June 18, 2024 21:49
- so nothing changes in get.ps1 technicially its the same thing 👍
@loadstring1
Copy link
Contributor Author

keeping this up-to-date so you can merge it without conflicts in the future

@Raphire
Copy link
Owner

Raphire commented Jun 25, 2024

@loadstring1 I like the way you implemented this, but the method recently mentioned in #38 is a bit cleaner and utilizes the installer to do most of the heavy lifting.

I have adapted this method and included some of your tricks aswell here: 91bd5c5 (This is pushed to an experimental branch)

P.S. I opted not to remove EdgeCore and EdgeUpdate. Removing EdgeCore seems to break Widgets, and may also break other OS functionality. Removing EdgeUpdate may cause Webview2 to not update anymore at all, which could pose security issues and/or cause certain apps that require Webview2 to not work at all.

@Raphire Raphire force-pushed the master branch 2 times, most recently from e48b6e6 to 53dcb06 Compare June 26, 2024 18:42
@loadstring1
Copy link
Contributor Author

loadstring1 commented Jun 27, 2024

@loadstring1 I like the way you implemented this, but the method recently mentioned in #38 is a bit cleaner and utilizes the installer to do most of the heavy lifting.

Thank you

P.S. I opted not to remove EdgeCore and EdgeUpdate. Removing EdgeCore seems to break Widgets, and may also break other OS functionality. Removing EdgeUpdate may cause Webview2 to not update anymore at all, which could pose security issues and/or cause certain apps that require Webview2 to not work at all.

My script deletes those two because i don't really care about widgets i don't use that feature myself

but good catch i didn't notice anything because i don't use widgets at all

and for webview2: it doesn't need updates to work inside roblox so that also made me notice nothing (and its the only reason why i didnt delete webview2 its because roblox uses that for prompts such as logging into roblox account in studio)

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.

None yet

3 participants