Skip to content

Commit

Permalink
fix empty model error in luis build
Browse files Browse the repository at this point in the history
  • Loading branch information
Qi Kang committed Mar 27, 2020
1 parent 65b6643 commit af548f3
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions BotProject/Templates/CSharp/Scripts/deploy.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Param(
[string] $environment,
[string] $luisAuthoringKey,
[string] $luisAuthoringRegion,
[string] $language,
[string] $language,
[string] $projFolder = $(Get-Location),
[string] $botPath,
[string] $logFile = $(Join-Path $PSScriptRoot .. "deploy_log.txt")
Expand Down Expand Up @@ -115,6 +115,9 @@ if ($luisAuthoringKey -and $luisAuthoringRegion) {
"models" = $noneEmptyModels
}

$luString = $noneEmptyModels | Out-String
Write-Host $luString

$luconfigjson | ConvertTo-Json -Depth 100 | Out-File $(Join-Path $remoteBotPath luconfig.json)

# Execute bf luis:build command
Expand All @@ -127,7 +130,7 @@ if ($luisAuthoringKey -and $luisAuthoringRegion) {
New-Item -ItemType Directory -Force -Path generated
}

bf luis:build --in .\ --botName $name --authoringKey $luisAuthoringKey --dialog --out .\generated --suffix $customizedEnv -f --region $luisAuthoringRegion
bf luis:build --luConfig $(Join-Path $remoteBotPath luconfig.json) --botName $name --authoringKey $luisAuthoringKey --dialog --out .\generated --suffix $customizedEnv -f --region $luisAuthoringRegion
}
else {
Write-Host "bf luis:build does not exist, use the following command to install:"
Expand Down

0 comments on commit af548f3

Please sign in to comment.