Skip to content
This repository was archived by the owner on Jan 15, 2025. It is now read-only.

Commit 01bbbd7

Browse files
Chris McConnelljoshgummersallmunozemilio
authored
Add component information to return (#1012)
* Rename ImportedAssets/ExportedAssets * Add support for component metadata. * Move to npm run test in vscode launch config * c# metadata working * All tests running. * Filter test/tests and allow negative patterns. * Fix path comparisons. * Address review comments. Co-authored-by: Josh Gummersall <[email protected]> Co-authored-by: Emilio Munoz <[email protected]>
1 parent bf8d2db commit 01bbbd7

File tree

39 files changed

+515
-127
lines changed

39 files changed

+515
-127
lines changed

packages/dialog/src/commands/dialog/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
*/
55

66
import { Command, flags } from '@microsoft/bf-cli-command'
7+
export { Component, Import, Imports, SchemaMerger} from '../../library/schemaMerger'
78

89
export default class DialogIndex extends Command {
910
static description = 'Dialog related commands for working with .schema and .dialog files.'

packages/dialog/src/commands/dialog/merge.ts

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3,28 +3,28 @@
33
* Licensed under the MIT License.
44
*/
55

6-
import {Command, flags} from '@microsoft/bf-cli-command'
6+
import { Command, flags } from '@microsoft/bf-cli-command'
77
import { SchemaMerger } from '../../library/schemaMerger'
88

99
export default class DialogMerge extends Command {
10-
static description = 'Merge `<kind>.schema` and `<kind>[.<locale>].uischema` definitions from a project and its dependencies into a single .schema for describing .dialog files and a per locale .uischema for describing how Composer shows them. If a dependent package has an ExportedAssets directory it is copied to ImportedAssets/<package> in the --imports directory.'
10+
static description = 'Merge `<kind>.schema` and `<kind>[.<locale>].uischema` definitions from a project and its dependencies into a single .schema for describing .dialog files and a per locale .uischema for describing how Composer shows them. If a dependent package has an "exported" directory it is copied to /<package> in the --imports directory.'
1111

1212
static args = [
13-
{name: 'patterns', required: true, description: 'Any number of glob regex patterns to match .csproj, .nuspec or package.json files.'},
13+
{ name: 'patterns', required: true, description: 'Any number of glob regex patterns to match .csproj, .nuspec or package.json files.' },
1414
]
1515

1616
static strict = false
1717

1818
static flags: flags.Input<any> = {
19-
checkOnly: flags.boolean({char: 'c', description: 'Check and do not write files.', default: false}),
20-
debug: flags.boolean({char: 'd', description: 'Generate debug files.', hidden: true, default: false}),
21-
extension: flags.string({description: 'Extension to include as a resource.', required: false, multiple: true, default: ['.dialog', '.lg', '.lu', '.schema', '.qna', '.uischema']}),
22-
help: flags.help({char: 'h'}),
23-
nugetRoot: flags.string({description: 'Nuget root directory for debugging.', hidden: true}),
24-
imports: flags.string({description: 'Output path for imported assets. Defaults to the directory of --out with an ImportedAssets directory.', required: false}),
25-
output: flags.string({char: 'o', description: 'Output path and filename for merged .schema and .uischema. Defaults to first project name.', required: false}),
26-
schema: flags.string({char: 's', description: 'Path to merged .schema file to use if merging .uischema only.', required: false}),
27-
verbose: flags.boolean({char: 'v', description: 'Show verbose logging of files as they are processed.', default: false}),
19+
checkOnly: flags.boolean({ char: 'c', description: 'Check and do not write files.', default: false }),
20+
debug: flags.boolean({ char: 'd', description: 'Generate debug files.', hidden: true, default: false }),
21+
extension: flags.string({ description: 'Extension to include as a resource.', required: false, multiple: true, default: ['.dialog', '.lg', '.lu', '.schema', '.qna', '.uischema'] }),
22+
help: flags.help({ char: 'h' }),
23+
imports: flags.string({ description: 'Output path for imported assets. Defaults to the directory of --out with an imported directory.', required: false }),
24+
nugetRoot: flags.string({ description: 'Nuget root directory for debugging.', hidden: true }),
25+
output: flags.string({ char: 'o', description: 'Output path and optional filename for merged .schema and .uischema. Defaults to first project name.', required: false }),
26+
schema: flags.string({ char: 's', description: 'Path to merged .schema file to use if merging .uischema only.', required: false }),
27+
verbose: flags.boolean({ char: 'v', description: 'Show verbose logging of files as they are processed.', default: false }),
2828
}
2929

3030
static examples = [
@@ -33,7 +33,7 @@ export default class DialogMerge extends Command {
3333
]
3434

3535
async run() {
36-
const {argv, flags} = this.parse(DialogMerge)
36+
const { argv, flags } = this.parse(DialogMerge)
3737
let merger = new SchemaMerger(argv, flags.output, flags.imports, flags.checkOnly, flags.verbose, this.log, this.warn, this.error, flags.extension, flags.schema, flags.debug, flags.nugetRoot)
3838
await merger.merge()
3939
}

0 commit comments

Comments
 (0)