Mar 29, 2018 - Install Using Chocolatey; Confused By Code Installer; Official Installs. Install cURL into the Windows 10 Bash shell using the Windows 10. In this article, I will show you how to install Chocolatey on Windows 10.Chocolatey is an easy-to-use Software Package Manager for Windows similar to apt on ubuntu/debian or brew on OSX.
That's it! All you need is choco.exe (that you get from the installation scripts) and you are good to go! No Visual Studio required.
Chocolatey installs in seconds. You are just a few steps from running choco right now!
choco
or choco -?
now, or see Getting Started for usage instructions.NOTES:
Run the following command:
With PowerShell, there is an additional step. You must ensure Get-ExecutionPolicy is not Restricted. We suggest using Bypass
to bypass the policy to get things installed or AllSigned
for quite a bit more security.
Get-ExecutionPolicy
. If it returns Restricted
, then run Set-ExecutionPolicy AllSigned
or Set-ExecutionPolicy Bypass -Scope Process
.NOTE: Please inspect https://chocolatey.org/install.ps1 prior to running any of these scripts to ensure safety. We already know it's safe, but you should verify the security and contents of any script from the internet you are not familiar with. All of these scripts download a remote PowerShell script and execute it on your machine.
We take security very seriously. Learn more.
With PowerShell, there is an additional step or two. You must ensure Get-ExecutionPolicy is not Restricted. We suggest using Bypass
to bypass the policy to get things installed or AllSigned
for quite a bit more security.
Get-ExecutionPolicy
. If it returns Restricted
, then run Set-ExecutionPolicy AllSigned
or Set-ExecutionPolicy Bypass
.With completely offline use of Chocolatey, you want to ensure you remove the default community package source (choco source list
followed by choco source remove -n chocolatey
, or however you would do that with a configuration manager like Puppet).
NOTE: If you have the licensed edition, see Setting up Licensed Edition with Puppet instead. This only additionally contains some package examples and setting up tab completion.
Here's an example of setting Chocolatey up with Puppet that sets up and configures Chocolatey, sets up an internal package repository, and shows setting up the licensed edition and ensuring some packages.
choco push
to push those items to your internal package repository (e.g. choco push chocolatey.0.10.7.nupkg -s http://internal_repo/ -k abc123
)This is the best method if you want to repeat it or include it in source control. It requires no change to your existing PowerShell to allow for remote unsigned scripts.
Create a file named installChocolatey.cmd
with the following:
You can also get to this file by going to https://chocolatey.org/installchocolatey.cmd.
If you prefer to have the install.ps1 file already, comment out the download line in the batch file and download the install.ps1
from chocolatey.org and save it as install.ps1
next to the installChocolatey.cmd
file.
Run installChocolatey.cmd
from an elevated cmd.exe
command prompt and it will install the latest version of Chocolatey. You can not run this from powershell.exe
without making changes to your execution policy.
NOTE: To create and save a .cmd
file, please use a text editor and nothing fancy like Microsoft Word or OneNote.
When you have Visual Studio 2010+ and the NuGet extension installed (pre-installed on any newer versions of Visual Studio), you can simply type the following three commands and you will have Chocolatey installed on your machine.
Install-Package chocolatey
Initialize-Chocolatey
Uninstall-Package chocolatey
You can also use NuGet command line to download Chocolatey:
nuget install chocolatey
or nuget install chocolatey -pre
Once you download it, open PowerShell (remote unsigned), navigate to the tools folder and run:
& .chocolateyInstall.ps1
You can also just download and unzip the Chocolatey package (.nupkg
is a fancy zip file):
zip
format.& .chocolateyInstall.ps1
to allow Chocolatey to install.choco upgrade chocolatey -y
and let it reinstall the same version, but at least it will be available for upgrades then.Please see installation of licensed edition.
Have a proxy? Try
See Installing Chocolatey Behind a Proxy Server
ChocolateyInstall
and set it to the folder you want Chocolatey to install to prior to installation (this environment variable must be set globally or available to PowerShell- it is not enough to simply make it available to your current command prompt session).'C:Chocolatey'
unless necessary.NOTE: There is one really important consideration when installing Chocolatey to a non-default location: Chocolatey only locks down the permissions to Admins when installed to the default location %PROGRAMDATA%Chocolatey
, which means the same thing as %SystemDrive%ProgramDataChocolatey
.If you are installing to another location, you will need to handle this yourself, i. e. restrict write access to Admins in case you so desire.This is due to alternative locations could have a range of permissions that should not be changed.See Why does Chocolatey install where it does and https://github.com/chocolatey/choco/issues/398 for more details.
Set the following environment variable prior to install:
chocolateyVersion
- controls what version of Chocolatey is installedIn PowerShell, it looks like this:
NOTE: This will only work with the installation methods that call https://chocolatey.org/install.ps1 as part of the install.
Set the following environment variable prior to install:
Film Komedi Indonesia Terbaik! Jadul Tv7 views. TOP 10 Funniest Comedians. Film komedi indonesia terbaik. Yt santai27 views. Celebrities With Weird/Hidden Talents. Film komedi indonesia terbaik. FILM KOMEDI INDONESIA TERBAIK SEPANJANG MASA. Celine Savina. Unsubscribe from. Film komedi indonesia terbaik. Unsubscribe from yt class? Komedi #FilmKomedi #FilmIndo #bioskopindo #KomediIndo #RekomendasiFilm SEMOGA KALIAN.
chocolateyUseWindowsCompression
- this will bypass the download and use of 7zip.In PowerShell, it looks like this:
NOTE: This will only work with the installation methods that call https://chocolatey.org/install.ps1 as part of the install.
NOTE: If your server is restricted to TLS 1.1+, you need to add additional logic to be able to download and install Chocolatey (this is not necessary when running Chocolatey normally as it does this automatically). If this is for organizational use, you should consider hosting the Chocolatey package internally and installing from there. Otherwise, please see this section.
If you see an error that looks similar to the following:
It's possible that you are attempting to install from a server that needs to use TLS 1.1 or TLS 1.2 (has restricted the use of TLS 1.0 and SSL v3), you have some options.
If you have the following:
You can just run the following instead of just the one-liner to get Chocolatey installed:
You need to download and unzip the Chocolatey package, then call the PowerShell install script from there. See the Download + PowerShell Method section below.
NOTE: This option should be a last resort and is considered to be a more advanced scenario - most things you do on Windows require administrative rights, especially surrounding software management, so you are going to be limited even in packages you attempt to install. If you are using the community package repository, there are over 200 packages you can install from the community repository without administrative permission - see https://chocolatey.org/packages?q=id%3Aportable+tag%3Aportable.
NonAdmin.ps1:
If you prefer or need cmd.exe example, please see https://gist.github.com/ferventcoder/78fa6b6f4d6e2b12c89680cbc0daec78
Once installed, Chocolatey can be upgraded in exactly the same way as any other package that has been installed using Chocolatey. Simply use the command to upgrade to the latest stable release of Chocolatey:
See uninstall.
Make sure you've reviewed More Install Options and looked over Troubleshooting. If you've done those things, reach out over the mailing list or over the chat (Gitter). The links to those can be found in the open source section of https://chocolatey.org/support.
This is addressed in Troubleshooting.
tl;dr - Chocolatey installs as a nupkg like everything else, a PowerShell install script just ensures that.
Chocolatey was born out of providing automation for Windows and doing that with packages, packages that could surround an installer but didn't necessarily need to. The Chocolatey install scripts use the Chocolatey package (a nupkg file itself) to be installed and upgraded as just another package. This means Chocolatey is 'eating its own dogfood' and it is unlikely we'd offer it as an MSI (native installer)as it would fly a bit in the face of what Chocolatey represents (although it is something that we would not rule out).
The installation actually ensures a couple of things:
PowerShell is installed and is set up properly.
PowerShell is a requirement for using Chocolatey, not just for install. It is what drives the package installation process in most cases. Every package can have binaries and/or installation/uninstallation scripts (written in PowerShell). Chocolatey is the framework and each package gets to define how it is installed, upgraded, and uninstalled. It's an extremely flexible framework that has been proven to meet the insanity that is the Windows software installation ecosystem. That flexibility would not be easily achieved without PowerShell.
We do recognize there are a few organizations that disable PowerShell, so it's very likely in the future our Business Edition will meet that need. PowerShell is a staple of Windows automation, so it is not the norm for an organization in this day and age to disable PowerShell.
Having an install process that uses PowerShell helps you determine quickly if Chocolatey will be able to be used in your environment.
You are open to doing things in a slightly different way, e.g. working with packages as opposed to installers.
You are open to the concept of using packages. Some folks might say this means we are asking folks to learn to 'do things 'our way' because we know better'. It's less about 'knowing better' and more about learning that Chocolatey does things in a slightly different way. It does that because the world of software is not just installers. Software goes beyond Programs and Features and a system that can track all of that also needs to as well. Package management is not a new concept in the world of software, perhaps just newer to Windows. If folks are not open to that, then they are probably not going to be open to Chocolatey. And that's completely fine. Chocolatey is not for everyone. We may eventually get to more of a masses approach. Right now we are targeting a specific type of audience - those that are looking for better ways to manage software on Windows and open to looking for the best process of doing that.
Most Windows users don’t pay much attention to how desktop programs are installed on their system. For years we’ve been trained to seek out a website, download an EXE or MSI file, and then click, click, click our way through the installation.
It’s an easy method, but it’s also time consuming because of the manual interaction.
A burgeoning project called Chocolatey wants to make it easy to install desktop apps without having to click through an interminable number of installation windows.
Chocolatey is a command line application installer for Windows based on a developer-centric package manager called NuGet. Unlike manual installations, Chocolatey adds, updates, and uninstalls programs in the background requiring very little user interaction.
Chocolatey has its own package feed that is created and maintained by the project’s community members.
Behind the scenes, most Chocolatey packages simply download a program’s official executable and install it without any further interaction from the user.
No, wait, hear me out!
Getting new programs the old fashioned way is very easy, but manual installs are also inefficient. Wouldn’t you rather spend your time checking out the latest cat videos on YouTube while your PC goes about installing programs by itself?
That’s the promise of Chocolatey. If the program has any dependencies, such as the .NET framework, Chocolatey will install those too. Avatar book 3 episode 1.
Chocolatey can also take care of multiple program installations.
Imagine cracking open a new PC, downloading Chocolatey and then typing a one-line command to install all the programs you’d like to have on your new machine. That's what Chocolatey does.
Getting Chocolatey onto your system is very simple since the commands can be copied and pasted into your command prompt from Chocolatey.org. To start, you need to open an elevated command prompt.
To do this in Windows 8.1, click on the Start button and go to the all apps screen. Under the Windows System heading find Command Prompt, right click-it and select Run as administrator. When the User Account Control window opens, authorize it by clicking Yes.
A command prompt window should open with something like C:WINDOWSsystem32.
Next, visit Chocolatey.org and copy the first box. At this writing, the commands were:
Paste it into the prompt, press Enter and your PC will take care of the rest.
Usually doing a copy and paste of commands is not advisable, but in this case it’s just fine.
So you can rest easier, let’s break the instructions down a little bit: These commands are telling your PC to launch PowerShell and don’t load any custom profiles a power user might have. Avatar legend of korra fanfiction. Next, it tells Windows to set the execution policy to unrestricted to allow any PowerShell script to be run and then download and run the Chocolatey install script.
Once you’ve got Chocolatey up and running, it’s time to start installing programs. Open an administrative command prompt again and type cinst [program name]
.
If you wanted to install VLC you’d type:
Pretty easy, right? The trick is that you need to know the exact name Chocolatey uses for each program. You can’t just type Chrome
or Google-Chrome
and expect Chocolatey to figure it out.
To find the names of programs, you can try playing around on the command line with the trial and error method (which works more often than you’d think). If you don't have that kind of time, search Chocolatey.org’s online package catalog for programs. You can also search for packages right on the command line:
There are two ways to install multiple programs in one sitting with Chocolatey. The first is to type multiple arguments into the command line. If you wanted to install VLC, GIMP, and Firefox you’d type:
For much larger batches of programs, however, you’re better off creating an XML document with a .config file extension and formatting it like so:
That basic document structure can include as many programs as you like, and can even include alternative sources other than Chocolatey’s community feed. For a more thorough tutorial on creating a multiple install file, check out developerFusion.
Updating installed programs via Chocolatey is simple too. Type cup [program name]
into an administrative command. To update DosBox, for example, type:
You can also update all your programs by typing cup all
. If your package is using an alternative source other than the main Chocolatey package feed, you can type:
Uninstalling a package is a little different. Going back to our example, you'd type the following to uninstall DosBox:
On the next page, we'll cover standardized commands and security concerns.