14 April 2023

Automatic update of Chocolatey packages

 If you are installed some software using https://chocolatey.org and want to keep it up to date, then open administrative Command Prompt (cmd.exe as administrator) and paste this line there:

schtasks /create /tn choco-update /tr "cup all -y" /sc daily /st 02:46 /ru SYSTEM /rl HIGHEST

This will create a scheduled task, which runs every day at 02:46 (nighttime) and updates all chocolatey packages (the command "cup all -y" does that).



To see all scheduled tasks, open taskschd.msc and see it for yourself:



To see log file, what actually has happened during last nightly sessions, open this file:

"C:\ProgramData\chocolatey\logs\chocolatey.log"



No comments:

Post a Comment