Skip to content

Instantly share code, notes, and snippets.

@flatlinebb
Last active August 19, 2016 17:59
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 flatlinebb/bf9babc3002988820f500b1f57b874b0 to your computer and use it in GitHub Desktop.
Save flatlinebb/bf9babc3002988820f500b1f57b874b0 to your computer and use it in GitHub Desktop.
Bart's 2nd gist
### To Run:
### In IE:
### http://boxstarter.org/package/nr/url?https://gist.githubusercontent.com/flatlinebb/....
## To Do:
# Command Prompt customization - reg file?
# Chrome no sign-in prompt
###### Boxstarter options
# Allow reboots
$Boxstarter.RebootOk=$true
# Is this a machine with no login password?
# $Boxstarter.NoPassword=$true
# Save my password securely and auto-login after a reboot
$Boxstarter.AutoLogin=$true
Disable-UAC
Update-ExecutionPolicy Unrestricted
Set-StartScreenOptions -EnableBootToDesktop -EnableSearchEverywhereInAppsView
Set-CornerNavigationOptions -EnableUsePowerShellOnWinX
Set-TaskbarOptions -Lock -Combine Always -Size Large
Set-WindowsExplorerOptions -EnableShowHiddenFilesFoldersDrives -EnableShowProtectedOSFiles -EnableShowFileExtensions -EnableShowFrequentFoldersInQuickAccess
########################
#### Make a Support folder
# C:\Support
if (!(Test-Path -Path C:\Support )) {
mkdir C:\Support
}
Write-BoxstarterMessage "Made Support folder"
#############
### Make the powerbutton "Restart" by default
reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v Start_PowerButtonAction /t REG_DWORD /d 4 /f
## Show "run" in start menu
reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v Start_ShowRun /t REG_DWORD /d 1 /f
##Dont highlight new apps
reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v Start_NotifyNewApps /t REG_DWORD /d 0 /f
##Show network places
reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v Start_ShowNetPlaces /t REG_DWORD /d 1 /f
##Show recent documents
reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v Start_ShowRecentDocs /t REG_DWORD /d 1 /f
Enable-RemoteDesktop
Disable-BingSearch
Disable-InternetExplorerESC
### Change IE to start with google ###
REG ADD "HKCU\Software\Microsoft\Internet Explorer\Main" /V "Start Page" /D "http://www.google.com/" /F
## Launch IE To test home page
start iexplore.exe
cinst 7zip.install
cinst GoogleChrome-AllUsers
# Kill Chrome window that opens
taskkill /F /IM chrome.exe
Chrome.exe --make-default-browser --no-first-run
taskkill /F /IM chrome.exe
# Kill any open IE windows
taskkill /F /IM iexplore.exe
cinst firefox
cinst flashplayeractivex
cinst flashplayerplugin
cinst flashplayerppapi
cinst jre8
cinst notepadplusplus.install
cinst aria2
cinst wget
cinst filezilla
cinst foxitreader
cinst malwarebytes
cinst pstools
cinst DotNet4.5.2
cinst PowerShell
cinst PSWindowsUpdate
cinst chocolatey
choco feature enable -n allowGlobalConfirmation
choco feature enable -n allowEmptyChecksums
cinst TelnetClient --source windowsfeatures
if (Test-PendingReboot) { Invoke-Reboot }
#### Move all on the desktop in this user to the Support folder
Write-BoxstarterMessage "About to do move shortcuts from Desktop to Support"
Move-Item -Path C:\Users\Public\Desktop\*.* -Destination C:\Support
##Get all user info
Write-BoxstarterMessage "About to do choco list"
choco list -localonly >C:\Support\myinfo.txt
Write-BoxstarterMessage "About to do whoami"
whoami /all /fo csv >C:\Support\myinfo.csv
whoami /all /fo csv >>C:\Support\myinfo.txt
Write-BoxstarterMessage "About to do getmac"
getmac >>C:\Support\myinfo.csv
getmac >>C:\Support\myinfo.txt
Write-BoxstarterMessage "About to do ipconfig"
ipconfig /all >>C:\Support\myinfo.csv
ipconfig /all >>C:\Support\myinfo.txt
#Write-BoxstarterMessage "About to do wmic"
#wmic csproduct get vendor,name,identifyingnumber >>C:\Support\myinfo.csv
#wmic csproduct get vendor,name,identifyingnumber >>C:\Support\myinfo.txt
if (Test-PendingReboot) { Invoke-Reboot }
Install-WindowsUpdate -getUpdatesFromMS -acceptEula
if (Test-PendingReboot) { Invoke-Reboot }
Install-WindowsUpdate -getUpdatesFromMS -acceptEula
if (Test-PendingReboot) { Invoke-Reboot }
Enable-UAC
Write-BoxstarterMessage "Boxstarter is ALL DONE!"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment