-
Notifications
You must be signed in to change notification settings - Fork 0
Closed
Description
Track implementation of the azdo boards iteration project list command.
Command Description
List the iteration (sprint) hierarchy for a project within an Azure DevOps organization. Iteration paths classify work by schedule and expose optional start/finish dates, all retrieved through the Work Item Tracking Classification Nodes REST API.
Command Signature
azdo boards iteration project list [organization/]<project>
- Aliases:
ls,l - Positional argument follows
[organization/]<project>parsing rules with default organization fallback.
Flags
--path,-p: Optional iteration path relative to the project root. When set, treat the node as the root for listing.--depth,-d: Optional integer (1–10) limiting depth. Default 3. Maps to$depth.--include-dates: Optional bool. When enabled, surfaceStart DateandFinish Datecolumns sourced from node attributes.- JSON export flags wired via
util.AddJSONFlags.
Behavior
- Resolve streams, parse
[organization/]<project>, and start/stop the progress indicator around API calls. - Acquire the Work Item Tracking client and call
classificationnodes/Iterationsusing eitherGetClassificationNodes(root listing) orGetClassificationNode(scoped path) with$depth. - Flatten the returned tree depth-first. For each node capture:
Name, fully-qualifiedPath,HasChildren,Level, and optionallyStartDate/FinishDate. ThePathmust remain untouched so users can copy it directly intoazdo boards work-item list --iteration. - When JSON export requested, emit an object with
json:"nodes"containing the ordered list. Each node entry must expose apathfield so scripts can feed the value to--iterationwithout parsing table text. Include date pointers withomitemptywhen requested. - Default path outputs a table via
ctx.Printer("list")with columnsName,Path,Level,Has Children, plus date columns when--include-datesis set. Use indentation prefixes to illustrate hierarchy while keeping thePathcolumn intact. - Validate
--depthbounds and surface descriptive errors for invalid paths or client failures.
Testing
- Cover root listing, scoped path listing, depth truncation, JSON export (assert
pathpresence), and error propagation using classification node mocks.
References
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels