Fix for issues 3086 and 3087 (Command uninstall --cli should not uninstall when the user have not answer "yes")
The fix consists of considering that the user cancelled the uninstaller when providing invalid confirmation or menu data.
The MenuBuilder class has been extended to be able to limit the number of tries that the user has to give a valid menu option. The current behavior (unlimited tries) is kept by default. The uninstaller limits the number of tries in the menu to be consistent with what is done with the confirmation messages (the number of tries is limited to 5).