Skip to content

regg00/ChocoMan

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Tests Docs GitHub issues

ChocoMan

A PowerShell wrapper around Chocolatey.

Why it exists

Mostly for fun, but I also got tired of parsing raw output of Chocolatey commands in my deployment scripts. I figured having each command outputs a standardized PowerShell object would help somehow.

Installing this module

This module is available in PowerShell Gallery:

Install-Module ChocoMan

Or, download it from here and save all of the files somewhere in your $PSModulePath.

Before you start

Before using this package, you need to make sure that Chocolatey is installed on your device.

You can valide this with the choco --version command.

PS C:\> choco --version
2.1.0

You can also install it using this module with the Install-Choco command.

PS C:\> Install-Choco
Chocolatey v2.1.0 installed

Using the module

First things first, you need to import it Import-Module ChocoMan

Hide the activity indicator

The activity indicator can be hidden by setting the ProgressPreference variable to SilentlyContinue

PS C:\> Set-Variable ProgressPreference SilentlyContinue ; Get-ChocoOutdated

Demo

Functions

Here's the status of each functions:

Command Status Notes
Get-ChocoApiKey Retrieves, saves or deletes an API key for a particular source
Get-ChocoConfig Retrieves the chocolatey configuration
Get-ChocoFeature Retrieves the chocolatey features
Get-ChocoOutdated Get the list of outdated chocolatey packages.
Get-ChocoPackage Get a specific locally installed chocolatey package.
Get-ChocoSources Get the list of chocolatey sources.
Get-ChocoVersion Get the version of chocolatey.
Get-ChocoManVersion Get the version of ChocoMan.
Get-ChocoPackageInfo Get information on an existing package.
Set-ChocoApiKey Edit API keys
Set-ChocoConfig Edit chocolatey configuration
Search-ChocoPackage Search for a chocolatey package.
Add-ChocoApiKey Adds a new API. Aliases to Set-ChocoApiKey. keuy
Add-ChocoSource Adds a new chocolatey source
Install-Choco Install chocolatey.
Install-ChocoPackage Installs a chocolatey package.
Uninstall-ChocoPackage Uninstalls a chocolatey package.
Update-ChocoPackage Updates a chocolatey package.
Remove-ChocoSource Removes a chocolatey source
New-ChocoPackage 🔜 Generates files necessary for a chocolatey package from a template
Build-ChocoPackage 🔜 Packages nuspec, scripts, and other Chocolatey package resources into a nupkg file
Publish-ChocoPackage 🔜 Pushes a compiled nupkg to a source

What else can I do?

There is plenty of help to read. Get started here