DevOps Yourself:

Fast-Track Your
Windows Development
Environment Setup

Justin James

 

Hours

 

Later

 

....

 

 

  • Multiple clicks to get anywhere

  • Deja vu - sense of installing same software

  • Aarg! should have got 64 bit version

  • Darn it, installed it to directory with a space

  • etc

  • etc

Problems Solved

Finding Applications

  • Use Boxstarter Chocolatey package
     

  • Detects Needed Reboots
     

  • Re-starts install script after reboots
     

  • https://boxstarter.org/

Bulk Install Packages

Installing Software

Install Chocolatey

http://chocolatey.org/

iex
(
    (new-object net.webclient).DownloadString
    (
        'https://chocolatey.org/install.ps1'
    )
)

Install BoxStarter


    choco install -y BoxStarter

Install from Gist

@powershell 
    -NoProfile -ExecutionPolicy Bypass 
    -Command "Install-BoxStarterPackage 
        -PackageName %temp%\\BoxstarterGist.txt"
@powershell 
    -NoProfile -ExecutionPolicy Bypass 
    -Command "Install-BoxStarterPackage 
        -PackageName [Gist Url]"

Gist File - Windows Config

Enable-RemoteDesktop

Set-CornerNavigationOptions -EnableUsePowerShellOnWinX

Set-ExplorerOptions 
    -EnableShowHiddenFilesFoldersDrives 
    -EnableShowProtectedOSFiles 
    -EnableShowFileExtensions 
    -EnableShowFullPathInTitlebar

Set-TaskbarOptions -Size Small -Lock

Gist File - Chocolatey

chocolatey feature enable -n=allowGlobalConfirmation

choco install git 
choco install nodejs 
choco install visualstudiocode 
choco install GoogleChrome 
.....

chocolatey feature disable -n=allowGlobalConfirmation

Gist File - Npm/Taskbar 

Install-ChocolateyPinnedTaskBarItem 
    "${env:UserProfile}\Desktop\code.lnk"

Install-ChocolateyPinnedTaskBarItem 
    "${env:ProgramFiles(x86)}\Google\Chrome\Application\chrome.exe"
npm config set loglevel http
npm config set spin false

npm install -g ionic
npm install -g cordova

Gist File - Code Config

$vsCodeDir = "${env:appdata}\Code"

If ((Test-Path $vsCodeDir)) {
	cp "${env:temp}\VisualStudioCode_keybinding.json" 
            "$vsCodeDir\keybinding.json"
	
	cp "${env:temp}\VisualStudioCode_UserSettings.json" 
            "$vsCodeDir\usersettings.json"
}
else {  
   Write-Host "Error: Visual Studio Code Directory, $vsCodeDir is missing"
}

Gist File - Git Clone


$projectDir = "${env:systemdrive}\projects"

If (!(Test-Path $projectDir)) {
	New-Item -Path $projectDir -ItemType Directory
}

cd $projectDir

git clone ....

Wrap up

  1. Install Chocolatey

  2. Install Boxstarter

  3. Run Gist file

New Initial Instructions

thank you

DevOps Yourself: Fast Track Your Windows Dev Box Setup

By Justin James

DevOps Yourself: Fast Track Your Windows Dev Box Setup

Intro to Software Package Manager for Windows called Chocolatey.

  • 2,589