-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathbuild.ps1
19 lines (13 loc) · 830 Bytes
/
build.ps1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
param($Task = 'Default')
"Starting build"
# Grab nuget bits, install modules, set build variables, start build.
Write-Host " [+] Install Dependent Modules" -Foreground Yellow
Get-PackageProvider -Name NuGet -ForceBootstrap | Out-Null
Uninstall-Module AzureRm -Verbose -Force -Confirm:$false
Install-Module PsScriptAnalyzer, Psake, PSDeploy, Pester, BuildHelpers, az.Profile, az.CognitiveServices, az.Resources -Force -AllowClobber
Write-Host " [+] Import Dependent Modules" -Foreground Yellow
Import-Module PsScriptAnalyzer, Psake, PSDeploy, Pester, BuildHelpers, az.Profile, az.CognitiveServices, az.Resources
Set-BuildEnvironment -GitPath "C:\Program Files\Git\bin\git.exe"
Write-Host " [+] InvokeBuild" -Foreground Yellow
Invoke-psake .\psake.ps1 -taskList $Task -nologo
exit ( [int]( -not $psake.build_success ) )