Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CopyXrmSolutionComponentsCommand -IncludePatches in Tasks #255

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,19 +1,21 @@
#
# Filename: ExtractSolution.ps1
# Filename: CopySolutionComponents.ps1
#
param(
[string]$FromSolutionName, #The unique CRM solution name
[string]$ToSolutionName, #The unique CRM solution name
[bool]$IncludePatches=$False, #Defines if include solution components from patches solutions.
[string]$CrmConnectionString, #The connection string as per CRM Sdk
[int]$Timeout=360
)

$ErrorActionPreference = "Stop"

Write-Verbose 'Entering MoveSolutionComponent.ps1'
Write-Verbose 'Entering CopySolutionComponents.ps1'

Write-Verbose "FromSolutionName = $FromSolutionName"
Write-Verbose "ToSolutionName = $ToSolutionName"
Write-Verbose "IncludePatches = $IncludePatches"
Write-Verbose "ConnectionString = $CrmConnectionString"
Write-Verbose "Timeout = $Timeout"

Expand All @@ -27,6 +29,6 @@ Write-Verbose "Importing CIToolkit: $xrmCIToolkit"
Import-Module $xrmCIToolkit
Write-Verbose "Imported CIToolkit"

Copy-XrmSolutionComponents -FromSolutionName $FromSolutionName -ToSolutionName $ToSolutionName -ConnectionString $CrmConnectionString -Timeout $Timeout -Verbose
Copy-XrmSolutionComponents -FromSolutionName $FromSolutionName -ToSolutionName $ToSolutionName -IncludePatches $IncludePatches -ConnectionString $CrmConnectionString -Timeout $Timeout -Verbose

Write-Verbose 'Leaving MoveSolutionComponent.ps1'
Write-Verbose 'Leaving CopySolutionComponents.ps1'
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,14 @@ Write-Verbose 'Entering MSCRMCopySolutionComponents.ps1'
$crmConnectionString = Get-VstsInput -Name crmConnectionString -Require
$fromSolutionName = Get-VstsInput -Name fromSolutionName -Require
$toSolutionName = Get-VstsInput -Name toSolutionName -Require
$includePatches = Get-VstsInput -Name includePatches -AsBool
$crmConnectionTimeout = Get-VstsInput -Name crmConnectionTimeout -Require -AsInt

#Print Verbose
Write-Verbose "crmConnectionString = $crmConnectionString"
Write-Verbose "fromSolutionName = $fromSolutionName"
Write-Verbose "toSolutionName = $toSolutionName"
Write-Verbose "includePatches = $includePatches"
Write-Verbose "crmConnectionTimeout = $crmConnectionTimeout"

#MSCRM Tools
Expand All @@ -27,6 +29,6 @@ if (-not $mscrmToolsPath)
Write-Error "MSCRM_Tools_Path not found. Add 'Power DevOps Tool Installer' before this task."
}

& "$mscrmToolsPath\xRMCIFramework\9.0.0\CopySolutionComponents.ps1" -fromSolutionName "$fromSolutionName" -toSolutionName "$toSolutionName" -crmConnectionString "$CrmConnectionString" -Timeout $crmConnectionTimeout
& "$mscrmToolsPath\xRMCIFramework\9.0.0\CopySolutionComponents.ps1" -fromSolutionName "$fromSolutionName" -toSolutionName "$toSolutionName" -includePatches $includePatches -crmConnectionString "$CrmConnectionString" -Timeout $crmConnectionTimeout

Write-Verbose 'Leaving MSCRMCopySolutionComponents.ps1'
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
"demands": [],
"version": {
"Major": 12,
"Minor": 0,
"Patch": 2
"Minor": 1,
"Patch": 0
},
"minimumAgentVersion": "1.95.0",
"instanceNameFormat": "Add components from : $(fromSolutionName) to $(toSolutionName)",
Expand Down Expand Up @@ -43,6 +43,14 @@
"required": true,
"helpMarkDown": "The unique name of the target solution"
},
{
"name": "includePatches",
"type": "boolean",
"label": "Include Patches",
"defaultValue": "false",
"required": false,
"helpMarkDown": "If set to true will include components from patches solutions"
},
{
"name": "crmConnectionTimeout",
"type": "string",
Expand Down
1 change: 1 addition & 0 deletions tasks-yaml-schema.md
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,7 @@
crmConnectionString: {String}
fromSolutionName:{String}
toSolutionName: {String}
includePatches: {Boolean}
```

### MSCRM Split Plugin Assembly
Expand Down