Skip to content

Commit 6a54559

Browse files
committed
service scaffold and cleanup
1 parent bec1058 commit 6a54559

20 files changed

Lines changed: 944 additions & 85 deletions

File tree

packages/b2c-cli/src/commands/scaffold/info.ts

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -79,10 +79,6 @@ export default class ScaffoldInfo extends BaseCommand<typeof ScaffoldInfo> {
7979
ui.div({text: 'Source:', width: 15, padding: [0, 2, 0, 0]}, {text: scaffold.source});
8080
ui.div({text: 'Description:', width: 15, padding: [0, 2, 0, 0]}, {text: scaffold.manifest.description});
8181

82-
if (scaffold.manifest.tags && scaffold.manifest.tags.length > 0) {
83-
ui.div({text: 'Tags:', width: 15, padding: [0, 2, 0, 0]}, {text: scaffold.manifest.tags.join(', ')});
84-
}
85-
8682
// Parameters
8783
if (scaffold.manifest.parameters.length > 0) {
8884
ui.div({text: '\nParameters:', padding: [1, 0, 0, 0]});

packages/b2c-cli/src/commands/scaffold/list.ts

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@ interface ScaffoldListResponse {
2727
category: ScaffoldCategory;
2828
source: string;
2929
path: string;
30-
tags?: string[];
3130
}>;
3231
}
3332

@@ -53,11 +52,6 @@ const COLUMNS: Record<string, ColumnDef<Scaffold>> = {
5352
get: (s) => s.manifest.description,
5453
extended: true,
5554
},
56-
tags: {
57-
header: 'Tags',
58-
get: (s) => s.manifest.tags?.join(', ') || '-',
59-
extended: true,
60-
},
6155
path: {
6256
header: 'Path',
6357
get: (s) => s.path,
@@ -91,8 +85,7 @@ export default class ScaffoldList extends BaseCommand<typeof ScaffoldList> {
9185
static flags = {
9286
category: Flags.string({
9387
char: 'c',
94-
description: 'Filter by category (cartridge, custom-api, page-designer, job, metadata)',
95-
options: ['cartridge', 'custom-api', 'page-designer', 'job', 'metadata'],
88+
description: 'Filter by category',
9689
}),
9790
source: Flags.string({
9891
char: 's',
@@ -136,7 +129,6 @@ export default class ScaffoldList extends BaseCommand<typeof ScaffoldList> {
136129
category: s.manifest.category,
137130
source: s.source,
138131
path: s.path,
139-
tags: s.manifest.tags,
140132
})),
141133
};
142134

packages/b2c-cli/src/commands/scaffold/search.ts

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ interface ScaffoldSearchResponse {
2020
description: string;
2121
category: ScaffoldCategory;
2222
source: string;
23-
tags?: string[];
2423
}>;
2524
}
2625

@@ -58,13 +57,13 @@ const tableRenderer = new TableRenderer(COLUMNS);
5857
export default class ScaffoldSearch extends BaseCommand<typeof ScaffoldSearch> {
5958
static args = {
6059
query: Args.string({
61-
description: 'Search query (matches name, description, and tags)',
60+
description: 'Search query (matches name and description)',
6261
required: true,
6362
}),
6463
};
6564

6665
static description = withDocs(
67-
t('commands.scaffold.search.description', 'Search for scaffolds by name, description, or tags'),
66+
t('commands.scaffold.search.description', 'Search for scaffolds by name or description'),
6867
'/cli/scaffold.html#b2c-scaffold-search',
6968
);
7069

@@ -81,7 +80,6 @@ export default class ScaffoldSearch extends BaseCommand<typeof ScaffoldSearch> {
8180
category: Flags.string({
8281
char: 'c',
8382
description: 'Filter results by category',
84-
options: ['cartridge', 'custom-api', 'page-designer', 'job', 'metadata'],
8583
}),
8684
};
8785

@@ -105,7 +103,6 @@ export default class ScaffoldSearch extends BaseCommand<typeof ScaffoldSearch> {
105103
description: s.manifest.description,
106104
category: s.manifest.category,
107105
source: s.source,
108-
tags: s.manifest.tags,
109106
})),
110107
};
111108

packages/b2c-cli/src/commands/scaffold/validate.ts

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -86,14 +86,6 @@ function validateManifestStructure(manifest: ScaffoldManifest): ValidationIssue[
8686
issues.push({severity: 'error', message: error, file: 'scaffold.json'});
8787
}
8888

89-
if (!manifest.tags || manifest.tags.length === 0) {
90-
issues.push({
91-
severity: 'warning',
92-
message: 'Consider adding tags for better searchability',
93-
file: 'scaffold.json',
94-
});
95-
}
96-
9789
if (!manifest.postInstructions) {
9890
issues.push({
9991
severity: 'warning',

packages/b2c-tooling-sdk/data/scaffolds/cartridge/scaffold.json

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,7 @@
33
"displayName": "Cartridge",
44
"description": "Create a new B2C Commerce cartridge with standard structure",
55
"category": "cartridge",
6-
"version": "1.0",
76
"defaultOutputDir": "cartridges",
8-
"tags": ["cartridge", "sfra", "b2c", "commerce"],
97
"parameters": [
108
{
119
"name": "cartridgeName",

packages/b2c-tooling-sdk/data/scaffolds/controller/scaffold.json

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33
"displayName": "SFRA Controller",
44
"description": "Create an SFRA controller with route handlers and middleware",
55
"category": "cartridge",
6-
"version": "1.0",
7-
"tags": ["controller", "sfra", "route", "middleware", "cartridge"],
86
"parameters": [
97
{
108
"name": "controllerName",

packages/b2c-tooling-sdk/data/scaffolds/custom-api/scaffold.json

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,7 @@
22
"name": "custom-api",
33
"displayName": "Custom SCAPI",
44
"description": "Create a custom SCAPI endpoint with OAS 3.0 schema",
5-
"category": "custom-api",
6-
"version": "1.0",
7-
"tags": ["api", "scapi", "custom-api", "rest", "openapi"],
5+
"category": "cartridge",
86
"parameters": [
97
{
108
"name": "apiName",

packages/b2c-tooling-sdk/data/scaffolds/hook/scaffold.json

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33
"displayName": "Hook Implementation",
44
"description": "Create a hook implementation with hooks.json registration",
55
"category": "cartridge",
6-
"version": "1.0",
7-
"tags": ["hook", "extension", "ocapi", "scapi", "event", "cartridge"],
86
"parameters": [
97
{
108
"name": "hookName",

packages/b2c-tooling-sdk/data/scaffolds/job-step/scaffold.json

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,7 @@
22
"name": "job-step",
33
"displayName": "Custom Job Step",
44
"description": "Create a custom job step with steptypes.json registration",
5-
"category": "job",
6-
"version": "1.0",
7-
"tags": ["job", "step", "batch", "task", "chunk", "pipeline"],
5+
"category": "cartridge",
86
"parameters": [
97
{
108
"name": "stepId",

packages/b2c-tooling-sdk/data/scaffolds/page-designer-component/scaffold.json

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,7 @@
22
"name": "page-designer-component",
33
"displayName": "Page Designer Component",
44
"description": "Create a Page Designer component with meta JSON, script, and template",
5-
"category": "page-designer",
6-
"version": "1.0",
7-
"tags": ["page-designer", "component", "cms", "content", "visual"],
5+
"category": "cartridge",
86
"parameters": [
97
{
108
"name": "componentId",

0 commit comments

Comments
 (0)