Last active
January 14, 2020 11:19
-
-
Save jasamour/b0331e69e75d8cc0f0e31a1916b72216 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Boxstarter Script (Windows 10 settings and modern web deployment) | |
# Credit to github.com/elithrar | |
# Pre | |
Disable-UAC | |
# Set PC name | |
$computername = "JASM-PC" | |
if ($env:computername -ne $computername) { | |
Rename-Computer -NewName $computername | |
} | |
# Install applications | |
choco install -y sysinternals | |
choco install -y firacode | |
choco install -y inconsolata | |
choco install -y vscode | |
choco install -y postman | |
# Hyper-V | |
choco install -y Microsoft-Hyper-V-All -source windowsFeatures | |
# Docker | |
Enable-WindowsOptionalFeature -Online -FeatureName containers -All | |
RefreshEnv | |
choco install -y docker-for-windows | |
choco install -y vscode-docker | |
# Browsers | |
choco install -y googlechrome.dev | |
choco install -y firefox | |
# Software | |
choco install -y 7zip.install | |
choco install -y discord | |
choco install -y spotify | |
choco install -y dropbox | |
choco install -y playnite | |
choco install -y stretchly | |
choco install -y vlc | |
# VS Code Extensions | |
code --install-extension msjsdiag.debugger-for-chrome | |
code --install-extension msjsdiag.debugger-for-edge | |
code --install-extension akamud.vscode-theme-onedark | |
code --install-extension azemoh.one-monokai | |
code --install-extension christian-kohler.npm-intellisense | |
code --install-extension DigitalBrainstem.javascript-ejs-support | |
code --install-extension eg2.vscode-npm-script | |
code --install-extension esbenp.prettier-vscode | |
code --install-extension leizongmin.node-module-intellisense | |
code --install-extension PKief.material-icon-theme | |
code --install-extension robertohuertasm.vscode-icons | |
code --install-extension vthiery.prettify-selected-json | |
code --install-extension whizkydee.material-palenight-theme | |
code --install-extension xabikos.JavaScriptSnippets | |
# WSL | |
choco install -y Microsoft-Windows-Subsystem-Linux -source windowsfeatures | |
Invoke-WebRequest -Uri https://aka.ms/wsl-ubuntu-1804 -OutFile ~/Ubuntu.appx -UseBasicParsing | |
Add-AppxPackage -Path ~/Ubuntu.appx | |
RefreshEnv | |
Ubuntu1804 install --root | |
Ubuntu1804 run apt update | |
Ubuntu1804 run apt upgrade | |
# System-level configuration | |
Disable-BingSearch | |
Disable-GameBarTips | |
Set-WindowsExplorerOptions -EnableShowHiddenFilesFoldersDrives -EnableShowProtectedOSFiles -EnableShowFileExtensions | |
Set-TaskbarOptions -Size Small -Dock Bottom -Combine Full -Lock | |
Set-TaskbarOptions -Size Small -Dock Bottom -Combine Full -AlwaysShowIconsOn | |
Set-ItemProperty -Path HKLM:\Software\Microsoft\Windows\CurrentVersion\AppModelUnlock -Name AllowDevelopmentWithoutDevLicense -Value 1 | |
# Disable Xbox Gamebar | |
Set-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\GameDVR" -Name AppCaptureEnabled -Type DWord -Value 0 | |
Set-ItemProperty -Path "HKCU:\System\GameConfigStore" -Name GameDVR_Enabled -Type DWord -Value 0 | |
# Turn off People in Taskbar | |
If (-Not (Test-Path "HKCU:SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\People")) { | |
New-Item -Path HKCU:SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\People | Out-Null | |
} | |
Set-ItemProperty -Path "HKCU:SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\People" -Name PeopleBand -Type DWord -Value 0 | |
# Change Explorer home screen back to "This PC" | |
Set-ItemProperty -Path HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced -Name LaunchTo -Type DWord -Value 1 | |
# File Explorer | |
Set-ItemProperty -Path HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced -Name NavPaneExpandToCurrentFolder -Value 1 | |
Set-ItemProperty -Path HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced -Name NavPaneShowAllFolders -Value 1 | |
Set-ItemProperty -Path HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced -Name MMTaskbarMode -Value 2 | |
# Change Windows Updates to "Notify to schedule restart" | |
Set-ItemProperty -Path HKCU:\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings -Name UxOption -Type DWord -Value 1 | |
# Disable P2P Update downlods outside of local network | |
Set-ItemProperty -Path HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\DeliveryOptimization\Config -Name DODownloadMode -Type DWord -Value 1 | |
Set-ItemProperty -Path HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\DeliveryOptimization -Name SystemSettingsDownloadMode -Type DWord -Value 3 | |
# Privacy: Let apps use my advertising ID: Disable | |
Set-ItemProperty -Path HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\AdvertisingInfo -Name Enabled -Type DWord -Value 0 | |
# To Restore: | |
#Set-ItemProperty -Path HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\AdvertisingInfo -Name Enabled -Type DWord -Value 1 | |
# WiFi Sense: HotSpot Sharing: Disable | |
Set-ItemProperty -Path HKLM:\Software\Microsoft\PolicyManager\default\WiFi\AllowWiFiHotSpotReporting -Name value -Type DWord -Value 0 | |
# WiFi Sense: Shared HotSpot Auto-Connect: Disable | |
Set-ItemProperty -Path HKLM:\Software\Microsoft\PolicyManager\default\WiFi\AllowAutoConnectToWiFiSenseHotspots -Name value -Type DWord -Value 0 | |
# Start Menu: Disable Bing Search Results | |
Set-ItemProperty -Path HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Search -Name BingSearchEnabled -Type DWord -Value 0 | |
# Cleanup applications | |
function removeApp { | |
Param ([string]$appName) | |
Write-Output "Trying to remove $appName" | |
Get-AppxPackage $appName -AllUsers | Remove-AppxPackage | |
Get-AppXProvisionedPackage -Online | Where DisplayNam -like $appName | Remove-AppxProvisionedPackage -Online | |
} | |
$applicationList = @( | |
"Microsoft.BingNews" | |
"Microsoft.BingWeather" | |
"Microsoft.3DBuilder" | |
"Microsoft.BingFinance" | |
"Microsoft.BingSports" | |
"Microsoft.CommsPhone" | |
"Microsoft.GetHelp" | |
"Microsoft.Getstarted" | |
"Microsoft.Messaging" | |
"Microsoft.Microsoft3DViewer" | |
"Microsoft.Office.OneNote" | |
"Microsoft.Print3D" | |
"Microsoft.WindowsMaps" | |
"Microsoft.WindowsPhone" | |
"Microsoft.Office.Sway" | |
"Microsoft.NetworkSpeedTest" | |
"Microsoft.FreshPaint" | |
"Microsoft.XboxApp" | |
"Microsoft.XboxIdentityProvider" | |
"Microsoft.YourPhone" | |
"Microsoft.ZuneMusic" | |
"Microsoft.ZuneVideo" | |
"*Minecraft*" | |
"*MarchofEmpires*" | |
"*Autodesk*" | |
"*BubbleWitch*" | |
"king.com*" | |
"G5*" | |
"*Dell*" | |
"*Facebook*" | |
"*Fitbit*" | |
"*Keeper*" | |
"*Netflix*" | |
"*Twitter*" | |
"*Plex*" | |
"*NORDCURRENT*" | |
"*ThumbmunkeysLtd*" | |
"*.Duolingo-LearnLanguagesforFree" | |
"*.EclipseManager" | |
"ActiproSoftwareLLC.562882FEEB491" | |
"*.AdobePhotoshopExpress" | |
); | |
foreach ($app in $applicationList) { | |
removeApp $app | |
} | |
# Uninstall McAfee Security App | |
$mcafee = gci "HKLM:\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall" | foreach { gp $_.PSPath } | ? { $_ -match "McAfee Security" } | select UninstallString | |
if ($mcafee) { | |
$mcafee = $mcafee.UninstallString -Replace "C:\Program Files\McAfee\MSC\mcuihost.exe", "" | |
Write "Uninstalling McAfee..." | |
start-process "C:\Program Files\McAfee\MSC\mcuihost.exe" -arg "$mcafee" -Wait | |
} | |
# Post | |
Enable-UAC | |
Enable-MicrosoftUpdate | |
Install-WindowsUpdate -acceptEula |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment