@we-scrum/cli 6.8.2 → 6.9.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/README.md +34 -20
- package/dist/cli.js +51 -39
- package/package.json +4 -4
- package/src/commands/iteration.ts +1 -1
- package/src/commands/story.ts +10 -0
- package/src/helpers/template.helper.ts +2 -0
- package/src/helpers/we-scrum.helper.ts +15 -0
- package/templates/get-next-task-breakpoint.hbs +11 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@we-scrum/cli",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.9.2",
|
|
4
4
|
"description": "Cli tool for we-scrum application",
|
|
5
5
|
"main": "dist/cli.js",
|
|
6
6
|
"bin": {
|
|
@@ -37,12 +37,12 @@
|
|
|
37
37
|
"@types/node": "^24.13.3",
|
|
38
38
|
"tsup": "^8.5.1",
|
|
39
39
|
"typescript": "^6.0.3",
|
|
40
|
-
"@my-devkit/cli": "2.1.0",
|
|
41
40
|
"@we-scrum/commands": "1.0.0",
|
|
41
|
+
"@we-scrum/models": "1.0.0",
|
|
42
42
|
"@my-devkit/core": "1.0.0",
|
|
43
|
+
"@we-scrum/utils": "1.0.0",
|
|
43
44
|
"@we-scrum/enums": "1.0.0",
|
|
44
|
-
"@
|
|
45
|
-
"@we-scrum/utils": "1.0.0"
|
|
45
|
+
"@my-devkit/cli": "2.1.0"
|
|
46
46
|
},
|
|
47
47
|
"scripts": {
|
|
48
48
|
"start": "node dist/cli.js",
|
|
@@ -16,7 +16,7 @@ export function registerIterationCommands(program: Command): void {
|
|
|
16
16
|
async (options) => {
|
|
17
17
|
await WeScrumHelper.updateIteration(options.name, {
|
|
18
18
|
capacity: options.capacity !== undefined ? Number(options.capacity) : undefined,
|
|
19
|
-
comment: options.comment,
|
|
19
|
+
comment: options.comment?.replaceAll('\\n', '\n')?.replaceAll('\\t', '\t'),
|
|
20
20
|
startDate: options.startDate !== undefined ? new Date(options.startDate) : undefined,
|
|
21
21
|
endDate: options.endDate !== undefined ? new Date(options.endDate) : undefined,
|
|
22
22
|
});
|
package/src/commands/story.ts
CHANGED
|
@@ -32,4 +32,14 @@ export function registerStoryCommands(program: Command): void {
|
|
|
32
32
|
return WeScrumHelper.getNextTask(options.identificationNumber);
|
|
33
33
|
}),
|
|
34
34
|
);
|
|
35
|
+
|
|
36
|
+
program
|
|
37
|
+
.command('remove-automation-breakpoint')
|
|
38
|
+
.description('Remove automation breakpoint')
|
|
39
|
+
.requiredOption('-i, --automationBreakpointId <id>', 'Automation breakpoint identification number')
|
|
40
|
+
.action(
|
|
41
|
+
runProjectCommand<{ automationBreakpointId: string }>(async (options) => {
|
|
42
|
+
await WeScrumHelper.removeAutomationBreakpoint(options.automationBreakpointId);
|
|
43
|
+
}),
|
|
44
|
+
);
|
|
35
45
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import Handlebars from 'handlebars';
|
|
2
2
|
import analysisDslLegend from '../../templates/analysis-dsl-legend.hbs';
|
|
3
3
|
import developStorySkill from '../../templates/develop-story-skill.hbs';
|
|
4
|
+
import getNextTaskBreakpoint from '../../templates/get-next-task-breakpoint.hbs';
|
|
4
5
|
import getNextTask from '../../templates/get-next-task.hbs';
|
|
5
6
|
import reviewAnalysisSkill from '../../templates/review-analysis-skill.hbs';
|
|
6
7
|
|
|
@@ -9,6 +10,7 @@ Handlebars.registerPartial('analysis-dsl-legend', analysisDslLegend);
|
|
|
9
10
|
const sources = {
|
|
10
11
|
'develop-story-skill': developStorySkill,
|
|
11
12
|
'get-next-task': getNextTask,
|
|
13
|
+
'get-next-task-breakpoint': getNextTaskBreakpoint,
|
|
12
14
|
'review-analysis-skill': reviewAnalysisSkill,
|
|
13
15
|
} as const;
|
|
14
16
|
|
|
@@ -5,6 +5,7 @@ import {
|
|
|
5
5
|
MarkRelationChangeAsDoneCommand,
|
|
6
6
|
MarkRouteChangeAsDoneCommand,
|
|
7
7
|
MarkTaskAsDoneCommand,
|
|
8
|
+
RemoveAutomationBreakpointCommand,
|
|
8
9
|
TakeEnumerationChangeCommand,
|
|
9
10
|
TakeObjectChangeCommand,
|
|
10
11
|
TakeRelationChangeCommand,
|
|
@@ -55,6 +56,13 @@ export class WeScrumHelper {
|
|
|
55
56
|
return `## Story ${identificationNumber}\n\nAll tasks are complete.`;
|
|
56
57
|
}
|
|
57
58
|
|
|
59
|
+
if (nextChange.automationBreakpointId) {
|
|
60
|
+
return renderTemplate('get-next-task-breakpoint', {
|
|
61
|
+
identificationNumber,
|
|
62
|
+
automationBreakpointId: nextChange.automationBreakpointId,
|
|
63
|
+
});
|
|
64
|
+
}
|
|
65
|
+
|
|
58
66
|
const analysisChange = StorySectionHelper.mapSingleChange(nextChange);
|
|
59
67
|
const isTodo = nextChange.progress.status === ProgressStatus.ToDo;
|
|
60
68
|
const developmentPolicy = await this.getChangeDevelopmentPolicy(nextChange);
|
|
@@ -165,6 +173,13 @@ export class WeScrumHelper {
|
|
|
165
173
|
}
|
|
166
174
|
}
|
|
167
175
|
|
|
176
|
+
public static async removeAutomationBreakpoint(automationBreakpointId: string): Promise<void> {
|
|
177
|
+
await this.post(
|
|
178
|
+
'project-management/remove-automation-breakpoint',
|
|
179
|
+
TypeHelper.transform(RemoveAutomationBreakpointCommand, { automationBreakpointId }),
|
|
180
|
+
);
|
|
181
|
+
}
|
|
182
|
+
|
|
168
183
|
public static async updateIteration(
|
|
169
184
|
name: string,
|
|
170
185
|
options: { capacity?: number; comment?: string; startDate?: Date; endDate?: Date },
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
## Story {{identificationNumber}}
|
|
2
|
+
|
|
3
|
+
Development is paused: an automation breakpoint is set on the next change.
|
|
4
|
+
|
|
5
|
+
The story is partially developed and waiting for resumption. Do not proceed until the user explicitly confirms it is fine to continue.
|
|
6
|
+
|
|
7
|
+
## Next steps
|
|
8
|
+
|
|
9
|
+
1. Wait for the user to confirm they want to resume development.
|
|
10
|
+
2. Once confirmed, run `we-scrum remove-automation-breakpoint --automationBreakpointId "{{automationBreakpointId}}"` to clear the breakpoint.
|
|
11
|
+
3. Call `get_next_task` again to resume.
|