Skip to content

Instantly share code, notes, and snippets.

@henriquecarv
Last active March 16, 2019 17:27
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 henriquecarv/e87e2d03ff753089a22ef36c77681bd6 to your computer and use it in GitHub Desktop.
Save henriquecarv/e87e2d03ff753089a22ef36c77681bd6 to your computer and use it in GitHub Desktop.
Basic Windows 10 setup
#Open CMD and execute START http://boxstarter.org/package/url? FOLLOWED BY THIS GIST'S URL
function SetPowerPlan([string]$PreferredPlan)
{
Write-Host "Setting Powerplan to $PreferredPlan"
$guid = (Get-WmiObject -Class win32_powerplan -Namespace root\cimv2\power -Filter "ElementName='$PreferredPlan'").InstanceID.tostring()
$regex = [regex]"{(.*?)}$"
$newpowerVal = $regex.Match($guid).groups[1].value
# setting power setting to high performance
powercfg -S $newpowerVal
}
# Boxstarter options
$Boxstarter.RebookOk=$true # Allow reboots?
$Boxstarter.NoPassword=$false # Is this a machine with no login password?
$Boxstarter.AutoLogin=$true # Save my password securely and auto-login after a reboot
#Basic setup
Update-ExecutionPolicy Unrestricted
Disable-InternetExplorerESC # Turns off IE Enhansed Security Configuration that is on by default on Server OS versions
Disable-UAC
###########################################
# Set explorer options #
###########################################
Set-WindowsExplorerOptions -EnableShowFileExtensions -EnableShowFullPathInTitleBar
# Update Windows and reboot if necessary
Install-WindowsUpdate -AcceptEula
if (Test-PendingReboot) { Invoke-Reboot }
# Power plan setup
#SetPowerPlan "High performance"
#dev tools
cinst jre8
cinst jdk8
if (Test-PendingReboot) { Invoke-Reboot }
#Browsers
cinst adblockplusie
cinst googlechrome
cinst firefox
#Other essential tools
cinst 7zip
cinst foxitreader
cinst ccleaner
cinst k-litecodecpackmega
cinst filezilla
cinst gimp
cinst pgadmin4
cinst teamviewer
cinst googledrive
cinst teracopy
cinst cdburnerxp
cinst lightshot
if (Test-PendingReboot) { Invoke-Reboot }
# Update Windows and reboot if necessary
Install-WindowsUpdate -AcceptEula
#--- Rename the Computer ---
# Requires restart, or add the -Restart flag
$computername = "Enzo-PC"
if ($env:computername -ne $computername) {
Rename-Computer -NewName $computername
}
if (Test-PendingReboot) { Invoke-Reboot }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment