I want to clean a computer to a near-pristine state with Windows 10 after having tried Ubuntu 18.04 on it. I have all the overall procedure under the belt.
The last detail is that the boot loader still sees an ubuntu entry. This is because there is a legacy EFI/ubuntu directory in the EFI partition. I would like to clean that too.
Windows installer, and expectation
When reinstalling Windows I don't want go as far as making a new user profile though.
I understand from the discussion in Completely remove Ubuntu from Windows 10 PC that, even when you proceed with the repair mode in Windows installer, that that EFI directory will survive. To remove it you need to act from a user profile using dedicated commands. This is another guided tour I bumped in: https://www.makeuseof.com/tag/delete-boot-menu-options-windows/ My first option is to avoid this avenue.
Ubuntu installer, and questions
Likewise, before reinstalling Windows 10, I can use the Ubuntu Live USB to mount and manipulate the EFI partition.
sudo rm -rf EFI/ubuntu from the terminal would clean that directory (repeat: not partition).
The questions are:
- Is that safe and in which way it is not?
Are there, for example, other files in the EFI partition keeping the books of the contents and potentially throwing exceptions down the line? There is another directory
EFI/BOOT, for example, containing BOOTX64.EFI and fbx64.efi.
Or would the boot loader and the future Windows 10 splash into and roam around
EFI/windows, insouciant of what its siblings are/were?
If this perhaps safer using a better command than
Do-nothing versus Do-nothing-harmful
I am aware that keeping
EFI/ubuntu is no harm.
I would know whether removing it is just as much so, and opt accordingly.