Skip to content

Instantly share code, notes, and snippets.

@omniscient
Last active April 14, 2016 03:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save omniscient/66d5b0c3d61fbb151d9d5b6dc5a16c10 to your computer and use it in GitHub Desktop.
Save omniscient/66d5b0c3d61fbb151d9d5b6dc5a16c10 to your computer and use it in GitHub Desktop.
Win2012 boxstarter script
######## Boxstarter script - based on https://gist.github.com/omniscient/dd373c05d9e5c76d193e
###############
#### notes ####
###############
### running remotely on VM fails on Configuring CredSSP settings
## check http://blogs.technet.com/b/heyscriptingguy/archive/2012/12/30/understanding-powershell-remote-management.aspx
### running locally on VM
## if connected, it will show login screen after restart, but is still working
### other notes
## Boxstarter repeats the _entire_ script after restart. For already-installed packages, Chocolatey will take a couple seconds each to verify. This can get tedious, so consider putting packages that require a reboot near the beginning of the script.
## Boxstarter automatically disables windows update so you don't need to do that at the beginning of the script.
### last run
## completed successfully except for GFW
## required reboots
## took hours
## still need to "Update and Restart" afterwards - and to ensure UAC is enabled
######################################
#### make sure we're not bothered ####
######################################
Disable-MicrosoftUpdate
Disable-UAC
cinst 7zip.install
cinst adblockpluschrome
cinst adobereader
cinst baretail
cinst ccleaner
cinst ChocolateyGUI
cinst ConEmu
cinst curl
cinst directorymonitor
cinst docker
cinst DotNet4.5
cinst DotNet4.5.1
cinst dotnet4.6.1
cinst fiddler4
cinst filezilla
cinst Firefox
cinst git
cinst git.install
cinst gitextensions
cinst git-credential-winstore
cinst glasswire
cinst greenshot
cinst grepwin
cinst javaruntime
cinst notepadplusplus
cinst NuGet.CommandLine
cinst NugetPackageExplorer
cinst poshgit
cinst PowerShell
cinst procexp
cinst procmon
cinst pstools
cinst python
cinst speccy
cinst sysinternals
cinst vcredist2013
cinst windirstat
cinst winmerge
#################################
#### NOW get windows updates ####
#################################
Enable-MicrosoftUpdate
Install-WindowsUpdate -AcceptEula
#################
#### cleanup ####
#################
del C:\eula*.txt
del C:\install.*
del C:\vcredist.*
del C:\vc_red.*
###############################
#### windows configuration ####
###############################
### do this here so that it only happens once (shouldn't reboot any more at this point)
Enable-RemoteDesktop
Set-StartScreenOptions -EnableBootToDesktop -EnableDesktopBackgroundOnStart -EnableShowStartOnActiveScreen -EnableShowAppsViewOnStartScreen -EnableSearchEverywhereInAppsView -EnableListDesktopAppsFirst
Set-WindowsExplorerOptions -EnableShowHiddenFilesFoldersDrives -EnableShowProtectedOSFiles -EnableShowFileExtensions -EnableShowFullPathInTitleBar
TZUTIL /s "Eastern Standard Time"
Install-ChocolateyPinnedTaskBarItem "${env:ProgramFiles(x86)}\Fiddler2\Fiddler.exe"
Install-ChocolateyPinnedTaskBarItem "$env:programfiles\comemu\ConEmu64.exe"
Install-ChocolateyPinnedTaskBarItem "$($Boxstarter.programFiles86)\Google\Chrome\Application\chrome.exe"
################################
#### restore disabled stuff ####
################################
Enable-UAC
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment