Skip to content

Instantly share code, notes, and snippets.

@xioustic
Last active August 29, 2015 14:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save xioustic/d458c703774fe4ef5926 to your computer and use it in GitHub Desktop.
Save xioustic/d458c703774fe4ef5926 to your computer and use it in GitHub Desktop.
Boxstarter: Install Boxstarter, Chocolatey, and Windows Updates Rebooting as Necessary
START iexplore http://boxstarter.org/package/nr/url?https://gist.githubusercontent.com/Xioustic/d458c703774fe4ef5926/raw/b6a01dc4a62ed698df2a384213de0430a2c8eccd/boxstarter-updates.txt
# Elevate PowerShell and set common explorer options
Update-ExecutionPolicy Unrestricted
Set-WindowsExplorerOptions -EnableShowHiddenFilesFoldersDrives -EnableShowFileExtensions -EnableShowFullPathInTitleBar
# Allow unattended reboots for updating
$Boxstarter.RebootOk=$true
$Boxstarter.AutoLogin=$true
# Update Windows and reboot if necessary
Install-WindowsUpdate -AcceptEula
if (Test-PendingReboot) { Invoke-Reboot }
# Update any Packages
cup all
if (Test-PendingReboot) { Invoke-Reboot }
# Update Windows and reboot if necessary
Install-WindowsUpdate -AcceptEula
if (Test-PendingReboot) { Invoke-Reboot }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment