Managing software updates with Chocolatey

Prerequisites include: Admin permissions to a Windows Machine Chocolatey package manager

Today we're going to talk about how to use chocolaty to upgrade software on a Windows machine and to manage those upgrades as well. So to start off let's list what I have installed on this machine. And I want to specify the Elo flag here that's going to list only packages that are installed locally on this computer. If I don't specify that flag chocolate is going to reach out to thechocolaty.org repo and list. All of the packages available there, which is a lot more than what I want to worry about today. So the first thing I'm going to do is for one piece of software I can run the Choco upgrade command. Then I'm gonna go ahead and specify one package here is VLC that's going to go ahead and reach out to chocolaty.org. Look for a new version and then upgrade to that version so that's the way we can do it for one package if I want to do this for multiple packages. There's a little bit more efficient of a way to do this with the Choco outdated command and what that's going to do is it's going to list. Everything I have installed the current version and the latest available version in chocolaty.org. As well as there's a field on the end here, called pinned now pinned is a bit of a unique feature. Basically, if you have a version of software that you want to keep at that level and upgrade. Everything else around it. You would pin that software to the version you want it to stay at. OK so now that the command is finished running. I'm going to go ahead and pin some software. You'll see up at the top of the list. I have JDK 8. Now, for those of you have worked with Java before it is very picky about versioning so I'm going to use the Choco pin add to add a pin to this and specify dash and for name equals JDK 8. And now that specific version of JDK is pinned and won't be upgraded and to show this. I'm going to try and upgrade it right now. And the upgrade fails because the package is pinned. Now we can also specify specific versions in that command if we want to add a pin, so if I wanted to add a pin to let's pick on VLC again and I want to keep it at version 3 dot O dot 5. That's going to go ahead and pin that specific version of VLC in my software. So now that those are pinned. I don't have any others. I want to keep I want to upgrade everything else around it. I can run. Choco upgrade but this time instead of specifying a package name. I'm going to send it all packages. And just for good measure, I'll throw dash uai on here to auto confirm an auto accept any license agreements. And what this is gonna do is it's going to go through everything I have on that outdated list. That's not pinned and update it in place. Now this is doing it from chocolaty.org if you have a custom chocolaty repo in your organization that you want to point to that's fine, too, but I'm not using that for today. And that's it. That's how we use chocolaty to manage our software. Thank you all for tuning in.