Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Uninstall Chocolatey package

The Chocolatey package manager supports silent installations via the command below. It doesn't seem to have an uninstall command.

cinst install packagename

Is there a way to uninstall an application via Chocolatey?

like image 825
Shaun Danielz Avatar asked May 01 '12 18:05

Shaun Danielz


People also ask

How do I uninstall Chocolatey package?

Folder. Most of Chocolatey is contained in C:\ProgramData\chocolatey or whatever $env:ChocolateyInstall evaluates to. You can simply delete that folder.


2 Answers

As I answered here, you can use

cuninst packagename

to uninstall a package.

Details can be found at Uninstall Command.

Edit: For new versions, should use choco uninstall packagename.

like image 56
xuhdev Avatar answered Oct 17 '22 03:10

xuhdev


Update: Chocolatey now has primitive support for uninstall through 'cuninst packagename'. With that though the package authors need to provide a chocolateyUninstall.ps1 file that would undo all of the things that the install did. It's limited because

  • There are no functions defined in the Chocolatey PowerShell module that would help with uninstall
  • There is no automatic removal of MSIs
  • Uninstall only removes the most current version of a package in the machine repository (instead of giving you options to remove a certain one or all of them)
like image 26
Matt Avatar answered Oct 17 '22 04:10

Matt