Skip to content

Commit eebe556

Browse files
committed
fix: command name
1 parent 81f5465 commit eebe556

File tree

4 files changed

+10
-10
lines changed

4 files changed

+10
-10
lines changed

command-snapshot.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
},
1010
{
1111
"alias": [],
12-
"command": "lightning:preview:component",
12+
"command": "lightning:dev:component",
1313
"flagAliases": [],
1414
"flagChars": ["n"],
1515
"flags": ["flags-dir", "json", "name"],

schemas/lightning-preview-component.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
{
22
"$schema": "http://json-schema.org/draft-07/schema#",
3-
"$ref": "#/definitions/LightningPreviewComponentResult",
3+
"$ref": "#/definitions/LightningDevComponentResult",
44
"definitions": {
5-
"LightningPreviewComponentResult": {
5+
"LightningDevComponentResult": {
66
"type": "object",
77
"properties": {
88
"path": {

src/commands/lightning/dev/component.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,13 @@ import { SfCommand, Flags } from '@salesforce/sf-plugins-core';
99
import { Messages } from '@salesforce/core';
1010

1111
Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);
12-
const messages = Messages.loadMessages('@salesforce/plugin-lightning-dev', 'lightning.preview.component');
12+
const messages = Messages.loadMessages('@salesforce/plugin-lightning-dev', 'lightning.dev.component');
1313

14-
export type LightningPreviewComponentResult = {
14+
export type LightningDevComponentResult = {
1515
path: string;
1616
};
1717

18-
export default class LightningPreviewComponent extends SfCommand<LightningPreviewComponentResult> {
18+
export default class LightningDevComponent extends SfCommand<LightningDevComponentResult> {
1919
public static readonly summary = messages.getMessage('summary');
2020
public static readonly description = messages.getMessage('description');
2121
public static readonly examples = messages.getMessages('examples');
@@ -29,13 +29,13 @@ export default class LightningPreviewComponent extends SfCommand<LightningPrevie
2929
}),
3030
};
3131

32-
public async run(): Promise<LightningPreviewComponentResult> {
33-
const { flags } = await this.parse(LightningPreviewComponent);
32+
public async run(): Promise<LightningDevComponentResult> {
33+
const { flags } = await this.parse(LightningDevComponent);
3434

3535
const name = flags.name ?? 'world';
36-
this.log(`hello ${name} from /Users/nkruk/git/plugin-lightning-dev/src/commands/lightning/preview/component.ts`);
36+
this.log(`hello ${name}`);
3737
return {
38-
path: '/Users/nkruk/git/plugin-lightning-dev/src/commands/lightning/preview/component.ts',
38+
path: '',
3939
};
4040
}
4141
}

0 commit comments

Comments
 (0)