pi-gsd 2.0.1 → 2.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/pi-gsd-hooks.js +1532 -0
- package/package.json +3 -5
- package/.gsd/extensions/pi-gsd-hooks.ts +0 -973
- package/src/cli.ts +0 -644
- package/src/commands/base.ts +0 -67
- package/src/commands/commit.ts +0 -22
- package/src/commands/config.ts +0 -71
- package/src/commands/frontmatter.ts +0 -51
- package/src/commands/index.ts +0 -76
- package/src/commands/init.ts +0 -43
- package/src/commands/milestone.ts +0 -37
- package/src/commands/phase.ts +0 -92
- package/src/commands/progress.ts +0 -71
- package/src/commands/roadmap.ts +0 -40
- package/src/commands/scaffold.ts +0 -19
- package/src/commands/state.ts +0 -102
- package/src/commands/template.ts +0 -52
- package/src/commands/verify.ts +0 -70
- package/src/commands/workstream.ts +0 -98
- package/src/commands/wxp.ts +0 -65
- package/src/lib/commands.ts +0 -1040
- package/src/lib/config.ts +0 -385
- package/src/lib/core.ts +0 -1167
- package/src/lib/frontmatter.ts +0 -462
- package/src/lib/init.ts +0 -517
- package/src/lib/milestone.ts +0 -290
- package/src/lib/model-profiles.ts +0 -272
- package/src/lib/phase.ts +0 -1012
- package/src/lib/profile-output.ts +0 -237
- package/src/lib/profile-pipeline.ts +0 -556
- package/src/lib/roadmap.ts +0 -378
- package/src/lib/schemas.ts +0 -290
- package/src/lib/security.ts +0 -176
- package/src/lib/state.ts +0 -1175
- package/src/lib/template.ts +0 -246
- package/src/lib/uat.ts +0 -289
- package/src/lib/verify.ts +0 -879
- package/src/lib/workstream.ts +0 -524
- package/src/output.ts +0 -45
- package/src/schemas/pi-gsd-settings.schema.json +0 -80
- package/src/schemas/wxp.xsd +0 -619
- package/src/schemas/wxp.zod.ts +0 -318
- package/src/wxp/__tests__/arguments.test.ts +0 -86
- package/src/wxp/__tests__/conditions.test.ts +0 -106
- package/src/wxp/__tests__/executor.test.ts +0 -95
- package/src/wxp/__tests__/helpers.ts +0 -26
- package/src/wxp/__tests__/integration.test.ts +0 -166
- package/src/wxp/__tests__/new-features.test.ts +0 -222
- package/src/wxp/__tests__/parser.test.ts +0 -159
- package/src/wxp/__tests__/paste.test.ts +0 -66
- package/src/wxp/__tests__/schema.test.ts +0 -120
- package/src/wxp/__tests__/security.test.ts +0 -87
- package/src/wxp/__tests__/shell.test.ts +0 -85
- package/src/wxp/__tests__/string-ops.test.ts +0 -25
- package/src/wxp/__tests__/variables.test.ts +0 -65
- package/src/wxp/arguments.ts +0 -89
- package/src/wxp/conditions.ts +0 -78
- package/src/wxp/executor.ts +0 -191
- package/src/wxp/index.ts +0 -191
- package/src/wxp/parser.ts +0 -198
- package/src/wxp/paste.ts +0 -51
- package/src/wxp/security.ts +0 -102
- package/src/wxp/shell.ts +0 -81
- package/src/wxp/string-ops.ts +0 -44
- package/src/wxp/variables.ts +0 -109
package/src/commands/state.ts
DELETED
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
import { Args, Flags } from "@oclif/core";
|
|
2
|
-
import { BaseCommand } from "./base.js";
|
|
3
|
-
|
|
4
|
-
export class StateJsonCommand extends BaseCommand {
|
|
5
|
-
static override description = "Output GSD state as JSON";
|
|
6
|
-
static override flags = { ...BaseCommand.baseFlags };
|
|
7
|
-
|
|
8
|
-
async run() {
|
|
9
|
-
const { flags } = await this.parse(StateJsonCommand);
|
|
10
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
11
|
-
const state = await import("../lib/state.js");
|
|
12
|
-
state.cmdStateJson(cwd, raw);
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
export class StateGetCommand extends BaseCommand {
|
|
17
|
-
static override description = "Get a specific state field";
|
|
18
|
-
static override args = { field: Args.string({ required: true }) };
|
|
19
|
-
static override flags = { ...BaseCommand.baseFlags };
|
|
20
|
-
|
|
21
|
-
async run() {
|
|
22
|
-
const { flags, args } = await this.parse(StateGetCommand);
|
|
23
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
24
|
-
const state = await import("../lib/state.js");
|
|
25
|
-
state.cmdStateGet(cwd, args.field, raw);
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
export class StateUpdateCommand extends BaseCommand {
|
|
30
|
-
static override description = "Update a state field";
|
|
31
|
-
static override args = {
|
|
32
|
-
field: Args.string({ required: true }),
|
|
33
|
-
value: Args.string({ required: true }),
|
|
34
|
-
};
|
|
35
|
-
static override flags = { ...BaseCommand.baseFlags };
|
|
36
|
-
|
|
37
|
-
async run() {
|
|
38
|
-
const { flags, args } = await this.parse(StateUpdateCommand);
|
|
39
|
-
const { cwd } = this.resolveContext(flags);
|
|
40
|
-
const state = await import("../lib/state.js");
|
|
41
|
-
state.cmdStateUpdate(cwd, args.field, args.value);
|
|
42
|
-
}
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
export class StatePatchCommand extends BaseCommand {
|
|
46
|
-
static override description = "Patch multiple state fields";
|
|
47
|
-
static override args = { pairs: Args.string({ required: false }) };
|
|
48
|
-
static override flags = {
|
|
49
|
-
...BaseCommand.baseFlags,
|
|
50
|
-
field: Flags.string({ multiple: true, description: "field=value pair" }),
|
|
51
|
-
};
|
|
52
|
-
|
|
53
|
-
async run() {
|
|
54
|
-
const { flags, argv } = await this.parse(StatePatchCommand);
|
|
55
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
56
|
-
const state = await import("../lib/state.js");
|
|
57
|
-
// Parse remaining argv as key value pairs
|
|
58
|
-
const patches: Record<string, string> = {};
|
|
59
|
-
const rawArgv = (argv as string[]).filter((a) => !a.startsWith("--"));
|
|
60
|
-
for (let i = 0; i < rawArgv.length; i += 2) {
|
|
61
|
-
const key = rawArgv[i].replace(/^--/, "");
|
|
62
|
-
if (key && rawArgv[i + 1] !== undefined) patches[key] = rawArgv[i + 1];
|
|
63
|
-
}
|
|
64
|
-
state.cmdStatePatch(cwd, patches, raw);
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
export class StateAdvancePlanCommand extends BaseCommand {
|
|
69
|
-
static override description = "Advance to next plan";
|
|
70
|
-
static override flags = { ...BaseCommand.baseFlags };
|
|
71
|
-
|
|
72
|
-
async run() {
|
|
73
|
-
const { flags } = await this.parse(StateAdvancePlanCommand);
|
|
74
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
75
|
-
const state = await import("../lib/state.js");
|
|
76
|
-
state.cmdStateAdvancePlan(cwd, raw);
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
export class StateLoadCommand extends BaseCommand {
|
|
81
|
-
static override description = "Load and display state";
|
|
82
|
-
static override flags = { ...BaseCommand.baseFlags };
|
|
83
|
-
|
|
84
|
-
async run() {
|
|
85
|
-
const { flags } = await this.parse(StateLoadCommand);
|
|
86
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
87
|
-
const state = await import("../lib/state.js");
|
|
88
|
-
state.cmdStateLoad(cwd, raw);
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
export class StateUpdateProgressCommand extends BaseCommand {
|
|
93
|
-
static override description = "Update progress counters";
|
|
94
|
-
static override flags = { ...BaseCommand.baseFlags };
|
|
95
|
-
|
|
96
|
-
async run() {
|
|
97
|
-
const { flags } = await this.parse(StateUpdateProgressCommand);
|
|
98
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
99
|
-
const state = await import("../lib/state.js");
|
|
100
|
-
state.cmdStateUpdateProgress(cwd, raw);
|
|
101
|
-
}
|
|
102
|
-
}
|
package/src/commands/template.ts
DELETED
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { Args, Flags } from "@oclif/core";
|
|
2
|
-
import { BaseCommand } from "./base.js";
|
|
3
|
-
|
|
4
|
-
export class TemplateSelectCommand extends BaseCommand {
|
|
5
|
-
static override description = "Select a workflow template";
|
|
6
|
-
static override args = { type: Args.string({ required: true }) };
|
|
7
|
-
static override flags = { ...BaseCommand.baseFlags };
|
|
8
|
-
|
|
9
|
-
async run() {
|
|
10
|
-
const { flags, args } = await this.parse(TemplateSelectCommand);
|
|
11
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
12
|
-
const { cmdTemplateSelect } = await import("../lib/template.js");
|
|
13
|
-
cmdTemplateSelect(cwd, args.type, raw);
|
|
14
|
-
}
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
export class TemplateFillCommand extends BaseCommand {
|
|
18
|
-
static override description = "Fill a template with values";
|
|
19
|
-
static override args = { type: Args.string({ required: true }) };
|
|
20
|
-
static override flags = {
|
|
21
|
-
...BaseCommand.baseFlags,
|
|
22
|
-
phase: Flags.string(),
|
|
23
|
-
plan: Flags.string(),
|
|
24
|
-
name: Flags.string(),
|
|
25
|
-
type: Flags.string({ char: "t" }),
|
|
26
|
-
wave: Flags.string(),
|
|
27
|
-
fields: Flags.string({ description: "JSON fields" }),
|
|
28
|
-
};
|
|
29
|
-
|
|
30
|
-
async run() {
|
|
31
|
-
const { flags, args } = await this.parse(TemplateFillCommand);
|
|
32
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
33
|
-
const { cmdTemplateFill } = await import("../lib/template.js");
|
|
34
|
-
let extraFields: Record<string, string> = {};
|
|
35
|
-
if (flags.fields) {
|
|
36
|
-
try { extraFields = JSON.parse(flags.fields) as Record<string, string>; } catch { /* ignore */ }
|
|
37
|
-
}
|
|
38
|
-
cmdTemplateFill(
|
|
39
|
-
cwd,
|
|
40
|
-
args.type,
|
|
41
|
-
{
|
|
42
|
-
phase: flags.phase ?? undefined,
|
|
43
|
-
plan: flags.plan ?? undefined,
|
|
44
|
-
name: flags.name ?? undefined,
|
|
45
|
-
type: flags.type ?? undefined,
|
|
46
|
-
wave: flags.wave ?? undefined,
|
|
47
|
-
...extraFields,
|
|
48
|
-
},
|
|
49
|
-
raw,
|
|
50
|
-
);
|
|
51
|
-
}
|
|
52
|
-
}
|
package/src/commands/verify.ts
DELETED
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
import { Args, Flags } from "@oclif/core";
|
|
2
|
-
import { BaseCommand } from "./base.js";
|
|
3
|
-
|
|
4
|
-
export class ValidateConsistencyCommand extends BaseCommand {
|
|
5
|
-
static override description = "Validate planning consistency";
|
|
6
|
-
static override flags = { ...BaseCommand.baseFlags };
|
|
7
|
-
|
|
8
|
-
async run() {
|
|
9
|
-
const { flags } = await this.parse(ValidateConsistencyCommand);
|
|
10
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
11
|
-
const v = await import("../lib/verify.js");
|
|
12
|
-
v.cmdValidateConsistency(cwd, raw);
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
export class ValidateHealthCommand extends BaseCommand {
|
|
17
|
-
static override description = "Check .planning/ health";
|
|
18
|
-
static override flags = {
|
|
19
|
-
...BaseCommand.baseFlags,
|
|
20
|
-
repair: Flags.boolean({ description: "Auto-repair issues", default: false }),
|
|
21
|
-
};
|
|
22
|
-
|
|
23
|
-
async run() {
|
|
24
|
-
const { flags } = await this.parse(ValidateHealthCommand);
|
|
25
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
26
|
-
const v = await import("../lib/verify.js");
|
|
27
|
-
v.cmdValidateHealth(cwd, { repair: flags.repair }, raw);
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
export class ValidateAgentsCommand extends BaseCommand {
|
|
32
|
-
static override description = "Validate agent configurations";
|
|
33
|
-
static override flags = { ...BaseCommand.baseFlags };
|
|
34
|
-
|
|
35
|
-
async run() {
|
|
36
|
-
const { flags } = await this.parse(ValidateAgentsCommand);
|
|
37
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
38
|
-
const v = await import("../lib/verify.js");
|
|
39
|
-
v.cmdValidateAgents(cwd, raw);
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
export class VerifyCommand extends BaseCommand {
|
|
44
|
-
static override description = "Run UAT verification";
|
|
45
|
-
static override args = { phase: Args.string({ required: false }) };
|
|
46
|
-
static override flags = {
|
|
47
|
-
...BaseCommand.baseFlags,
|
|
48
|
-
plan: Flags.string({ description: "Plan to verify" }),
|
|
49
|
-
};
|
|
50
|
-
|
|
51
|
-
async run() {
|
|
52
|
-
const { flags, args } = await this.parse(VerifyCommand);
|
|
53
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
54
|
-
const v = await import("../lib/verify.js");
|
|
55
|
-
// verify command runs consistency check as primary action
|
|
56
|
-
v.cmdValidateConsistency(cwd, raw);
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
export class AuditUatCommand extends BaseCommand {
|
|
61
|
-
static override description = "Audit UAT results";
|
|
62
|
-
static override flags = { ...BaseCommand.baseFlags };
|
|
63
|
-
|
|
64
|
-
async run() {
|
|
65
|
-
const { flags } = await this.parse(AuditUatCommand);
|
|
66
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
67
|
-
const { cmdAuditUat } = await import("../lib/uat.js");
|
|
68
|
-
cmdAuditUat(cwd, raw);
|
|
69
|
-
}
|
|
70
|
-
}
|
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
import { Args, Flags } from "@oclif/core";
|
|
2
|
-
import { BaseCommand } from "./base.js";
|
|
3
|
-
|
|
4
|
-
export class WorkstreamCreateCommand extends BaseCommand {
|
|
5
|
-
static override description = "Create a new workstream";
|
|
6
|
-
static override args = { name: Args.string({ required: true }) };
|
|
7
|
-
static override flags = {
|
|
8
|
-
...BaseCommand.baseFlags,
|
|
9
|
-
"no-migrate": Flags.boolean({ description: "Skip migration", default: false }),
|
|
10
|
-
"migrate-name": Flags.string({ description: "Migration name" }),
|
|
11
|
-
};
|
|
12
|
-
|
|
13
|
-
async run() {
|
|
14
|
-
const { flags, args } = await this.parse(WorkstreamCreateCommand);
|
|
15
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
16
|
-
const ws = await import("../lib/workstream.js");
|
|
17
|
-
ws.cmdWorkstreamCreate(
|
|
18
|
-
cwd, args.name,
|
|
19
|
-
{ migrate: !flags["no-migrate"], migrateName: flags["migrate-name"] ?? null },
|
|
20
|
-
raw,
|
|
21
|
-
);
|
|
22
|
-
}
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
export class WorkstreamListCommand extends BaseCommand {
|
|
26
|
-
static override description = "List workstreams";
|
|
27
|
-
static override flags = { ...BaseCommand.baseFlags };
|
|
28
|
-
|
|
29
|
-
async run() {
|
|
30
|
-
const { flags } = await this.parse(WorkstreamListCommand);
|
|
31
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
32
|
-
const ws = await import("../lib/workstream.js");
|
|
33
|
-
ws.cmdWorkstreamList(cwd, raw);
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
export class WorkstreamStatusCommand extends BaseCommand {
|
|
38
|
-
static override description = "Show workstream status";
|
|
39
|
-
static override args = { name: Args.string({ required: true }) };
|
|
40
|
-
static override flags = { ...BaseCommand.baseFlags };
|
|
41
|
-
|
|
42
|
-
async run() {
|
|
43
|
-
const { flags, args } = await this.parse(WorkstreamStatusCommand);
|
|
44
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
45
|
-
const ws = await import("../lib/workstream.js");
|
|
46
|
-
ws.cmdWorkstreamStatus(cwd, args.name, raw);
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
export class WorkstreamCompleteCommand extends BaseCommand {
|
|
51
|
-
static override description = "Complete a workstream";
|
|
52
|
-
static override args = { name: Args.string({ required: true }) };
|
|
53
|
-
static override flags = { ...BaseCommand.baseFlags };
|
|
54
|
-
|
|
55
|
-
async run() {
|
|
56
|
-
const { flags, args } = await this.parse(WorkstreamCompleteCommand);
|
|
57
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
58
|
-
const ws = await import("../lib/workstream.js");
|
|
59
|
-
ws.cmdWorkstreamComplete(cwd, args.name, {}, raw);
|
|
60
|
-
}
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
export class WorkstreamSetCommand extends BaseCommand {
|
|
64
|
-
static override description = "Set active workstream";
|
|
65
|
-
static override args = { name: Args.string({ required: true }) };
|
|
66
|
-
static override flags = { ...BaseCommand.baseFlags };
|
|
67
|
-
|
|
68
|
-
async run() {
|
|
69
|
-
const { flags, args } = await this.parse(WorkstreamSetCommand);
|
|
70
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
71
|
-
const ws = await import("../lib/workstream.js");
|
|
72
|
-
ws.cmdWorkstreamSet(cwd, args.name, raw);
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
export class WorkstreamGetCommand extends BaseCommand {
|
|
77
|
-
static override description = "Get active workstream";
|
|
78
|
-
static override flags = { ...BaseCommand.baseFlags };
|
|
79
|
-
|
|
80
|
-
async run() {
|
|
81
|
-
const { flags } = await this.parse(WorkstreamGetCommand);
|
|
82
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
83
|
-
const ws = await import("../lib/workstream.js");
|
|
84
|
-
ws.cmdWorkstreamGet(cwd, raw);
|
|
85
|
-
}
|
|
86
|
-
}
|
|
87
|
-
|
|
88
|
-
export class WorkstreamProgressCommand extends BaseCommand {
|
|
89
|
-
static override description = "Show workstream progress";
|
|
90
|
-
static override flags = { ...BaseCommand.baseFlags };
|
|
91
|
-
|
|
92
|
-
async run() {
|
|
93
|
-
const { flags } = await this.parse(WorkstreamProgressCommand);
|
|
94
|
-
const { cwd, raw } = this.resolveContext(flags);
|
|
95
|
-
const ws = await import("../lib/workstream.js");
|
|
96
|
-
ws.cmdWorkstreamProgress(cwd, raw);
|
|
97
|
-
}
|
|
98
|
-
}
|
package/src/commands/wxp.ts
DELETED
|
@@ -1,65 +0,0 @@
|
|
|
1
|
-
import { Args, Flags } from "@oclif/core";
|
|
2
|
-
import { Command } from "@oclif/core";
|
|
3
|
-
import path from "node:path";
|
|
4
|
-
import { processWxp, WxpProcessingError } from "../wxp/index.js";
|
|
5
|
-
import { DEFAULT_SHELL_ALLOWLIST } from "../wxp/security.js";
|
|
6
|
-
|
|
7
|
-
export class WxpProcessCommand extends Command {
|
|
8
|
-
static override description = "Process WXP tags in a workflow file";
|
|
9
|
-
static override args = {
|
|
10
|
-
file: Args.string({ description: "File to process", required: false }),
|
|
11
|
-
};
|
|
12
|
-
static override flags = {
|
|
13
|
-
input: Flags.string({ description: "Input content string (alternative to file)" }),
|
|
14
|
-
arguments: Flags.string({ description: "Raw $ARGUMENTS string", default: "" }),
|
|
15
|
-
"project-root": Flags.string({ description: "Project root directory", default: process.cwd() }),
|
|
16
|
-
"pkg-root": Flags.string({ description: "Package root directory", default: process.cwd() }),
|
|
17
|
-
};
|
|
18
|
-
|
|
19
|
-
async run() {
|
|
20
|
-
const { flags, args } = await this.parse(WxpProcessCommand);
|
|
21
|
-
|
|
22
|
-
let content: string;
|
|
23
|
-
let filePath: string;
|
|
24
|
-
|
|
25
|
-
if (flags.input !== undefined) {
|
|
26
|
-
content = flags.input;
|
|
27
|
-
filePath = path.join(flags["project-root"], ".pi", "gsd", "workflows", "_inline.md");
|
|
28
|
-
} else if (args.file) {
|
|
29
|
-
const fs = await import("node:fs");
|
|
30
|
-
filePath = path.resolve(args.file);
|
|
31
|
-
content = fs.default.readFileSync(filePath, "utf8");
|
|
32
|
-
} else {
|
|
33
|
-
this.error("Provide a file argument or --input string");
|
|
34
|
-
return;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
const config = {
|
|
38
|
-
trustedPaths: [
|
|
39
|
-
{ position: "project" as const, path: ".pi/gsd" },
|
|
40
|
-
{ position: "pkg" as const, path: ".gsd/harnesses/pi/get-shit-done" },
|
|
41
|
-
],
|
|
42
|
-
untrustedPaths: [],
|
|
43
|
-
shellAllowlist: [...DEFAULT_SHELL_ALLOWLIST],
|
|
44
|
-
shellBanlist: [],
|
|
45
|
-
shellTimeoutMs: 30_000,
|
|
46
|
-
};
|
|
47
|
-
|
|
48
|
-
try {
|
|
49
|
-
const result = processWxp(
|
|
50
|
-
content,
|
|
51
|
-
filePath,
|
|
52
|
-
config,
|
|
53
|
-
flags["project-root"],
|
|
54
|
-
flags["pkg-root"],
|
|
55
|
-
flags.arguments,
|
|
56
|
-
);
|
|
57
|
-
process.stdout.write(result);
|
|
58
|
-
} catch (err) {
|
|
59
|
-
if (err instanceof WxpProcessingError) {
|
|
60
|
-
this.error(err.message, { exit: 1 });
|
|
61
|
-
}
|
|
62
|
-
throw err;
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
}
|