Skip to content

Add support to uninstall #789

@hohwille

Description

@hohwille

As a IDEasy user, I want to be able to uninstall the IDEasy product so that I can get rid of it in case I want to without further manual steps and knowing internal details how to do that.

We already support ide uninstall «tool» to uninstall a specific tool from my current project.
The idea is that if ide uninstall is called without any additional parameter, then IDEasy gets uninstalled.
To avoid accidents, an interactive question should be asked so the user must confirm his choice to uninstall the product (or to cancel in case he just forgot to specify the «tool» to uninstall).

This should more or less revert what has been done during installation/setup:

  • remove ourselves from PATH on Windows
  • remove variable IDE_ROOT on Windows
  • remove entries we made to .bashrc
  • remove entries we made to .zshrc (if exists and IDEasy entries are present)
  • remove $IDE_ROOT/_ide/ except for $IDE_ROOT/_ide/software
  • unset ide or other "commands" (aliases/functions) from current bash (unload) - since we are implementing Java and not bash code anymore, this does not make so much sense. We could do it in the wrapper script but it is extra effort for no reason.
  • Log a message on interaction that IDEasy has been uninstalled but to avoid loss of data, the end-user should manually remove his $IDE_ROOT folder - but with care since all his projects are located there.

For .bashrc and .zshrc changes also see #779

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

Status

✅ Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions