Public/Get-P1Packages.ps1
function Get-P1Packages { <# .Synopsis Get all required packages from PlannerOne NuGet server. .Description Connect to remote repository and get the latest release. .Parameter PlannerOneVersion The PlannerOne version to install (ex: 5.0). .Parameter NAVVersion The Dynamics NAV version (ex: 2016). #> [cmdletbinding()] param( [string] $PlannerOneVersion, [string] $NAVVersion ) Process { Write-Section "Reading PlannerOne package from repository..." if (Get-Command Find-Package -errorAction SilentlyContinue) { Write-Verbose "Find-Package exists" Find-Package -Source $SourceUrl } else { Write-Output "Find-Package doesn't exist, using NuGet" NuGet list -Source $SourceURL } } } |