Try {
    # setup
    $rootDrive = (get-location).Drive.Name + ":"
    $pathDeployments = Join-Path -Path "$rootDrive" -ChildPath "Deployments"
    $pathVersion = "1.0.0.0"

    # service paths
    $pathStateMachineServiceExe = "$pathDeployments\Services\StateMachineService\$pathVersion\AAT.Genie.StateMachineService.exe"
    $pathControllerServiceExe = "$pathDeployments\Services\ControllerService\$pathVersion\AAT.Genie.ControllerService.exe"
    $pathSyncServiceExe = "$pathDeployments\Services\SyncService\$pathVersion\AAT.Genie.SyncService.exe"

    # install util
    $pathInstall = "$rootDrive\WINDOWS\Microsoft.NET\Framework\v4.0.30319\InstallUtil.exe"

    Write-Host -ForegroundColor yellow "`n--- Services ---`n"

    Write-Host "Installing State Machine Service..." -NoNewline
    Invoke-Expression "$pathInstall /install $pathStateMachineServiceExe" | Out-Null
    Write-Host "done."

    Write-Host "Installing Controller Service..." -NoNewline
    Invoke-Expression "$pathInstall /install $pathControllerServiceExe" | Out-Null
    Write-Host "done."

    Write-Host "Installing Sync Service..." -NoNewline
    Invoke-Expression "$pathInstall /install $pathSyncServiceExe" | Out-Null
    Write-Host "done."
    
}
Catch {
    throw $_.Exception.Message
}