choco Operations¶
Manage choco (Chocolatey) packages (https://chocolatey.org).
Facts used in these operations: choco.ChocoPackages.
choco.install¶
Stateless operation
This operation will always execute commands and is not idempotent.
Install choco (Chocolatey).
Global arguments
This operation also inherits all global arguments.
choco.packages¶
Add/remove/update choco packages.
- packages: list of packages to ensure
- present: whether the packages should be installed
- latest: whether to upgrade packages without a specified version
Versions:
Package versions can be pinned like gem: <pkg>:<version>.
Example:
# Note: Assumes that 'choco' is installed and
# user has Administrator permission.
choco.packages(
name="Install Notepad++",
packages=["notepadplusplus"],
)
Global arguments
This operation also inherits all global arguments.