Skip to content

Instantly share code, notes, and snippets.

@jacobboykin
Last active March 2, 2017 02:29
Show Gist options
  • Select an option

  • Save jacobboykin/4c5a987d40a3a3d3b92050f3f62c4d9d to your computer and use it in GitHub Desktop.

Select an option

Save jacobboykin/4c5a987d40a3a3d3b92050f3f62c4d9d to your computer and use it in GitHub Desktop.
$setupEXE = "C:\Apps\Office-365\Source\setup.exe"
$arguments = "/download C:\Apps\Office-365\Source\Download.xml"
# Delete current office source if it exists
if (Test-Path "C:\Apps\Office-365\Source\Office") {
Remove-Item "C:\Apps\Office-365\Source\Office" -Recurse -Force
}
# Run setup.exe in download mode
Start-Process -FilePath $setupEXE -ArgumentList $arguments -Wait
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment