Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
0fc3d7b
feat: ✨add work item list command
tmeckel Jan 6, 2026
2b98f8d
docs:📄 add work item command documentation
tmeckel Jan 6, 2026
ab84130
refactor: replace slices.CompactFunc with custom uniqueByEq implement…
tmeckel Jan 7, 2026
f4108a1
refactor: simplify work item list logic
tmeckel Jan 7, 2026
c7ac389
fix(auth): 🐛 add debug logging and username generation
tmeckel Jun 3, 2026
d622d8b
feat(util): add preconfigured string builders and MustGenerate
tmeckel Jun 3, 2026
d9aec1b
refactor: simplify identity filter condition
tmeckel Jun 3, 2026
7d610d2
test(workitem): 🧪add tests for work item list command
tmeckel Jun 3, 2026
f5c69ce
style(workitem): 💅🏼remove trailing blank line
tmeckel Jun 3, 2026
a6d6ef3
feat(workitem): add filtering and sorting options
tmeckel Jun 3, 2026
38a5720
test(workitem): 🧪 add list filter and sort tests
tmeckel Jun 3, 2026
e40e453
docs(workitem): 📄document new list command options
tmeckel Jun 3, 2026
e0b9bdb
chore: 💅🏼 replace interface{} with any
tmeckel Jun 3, 2026
229bc10
feat(workitem): add priority sort field
tmeckel Jun 3, 2026
a89d6b9
docs(workitem): 📄 add priority to sort field docs
tmeckel Jun 3, 2026
2ded9f5
chore: add mise.toml and update golangci config
tmeckel Jun 3, 2026
9f54c78
fix: correct .PHONY declaration for tidy
tmeckel Jun 3, 2026
7ce3657
feat(workitem)!: combine sort field and direction into single flag
tmeckel Jun 3, 2026
4527baa
test(workitem): update tests for combined sort
tmeckel Jun 3, 2026
cf9c6f7
docs(workitem): 📄 update docs for combined sort flag
tmeckel Jun 3, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,7 @@ linters:
- dupl
- errorlint
- exhaustive
- goconst
- gocritic
#- gocyclo
- gosec
- misspell
- nilerr
Expand Down
9 changes: 9 additions & 0 deletions .mise.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[env]
_.file = ".env"

[tools]
go = "1.24"
"golangci-lint" = "2.12.2"
goreleaser = "latest"
prek = "latest"
gofumpt = "latest"
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ lint: ## lint source
@echo "Check for golangci-lint"; [ -e "$(shell which golangci-lint)" ]
@echo "Executing golangci-lint"; golangci-lint run -v --timeout $(TIMEOUT)

.PHONY: help
.PHONY: tidy
tidy: ## call go mod tidy on all existing go.mod files
find . -name go.mod -execdir go mod tidy \;

Expand Down
1 change: 1 addition & 0 deletions docs/azdo_boards.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ Work with Azure Boards resources.

* [azdo boards area](./azdo_boards_area.md)
* [azdo boards iteration](./azdo_boards_iteration.md)
* [azdo boards work-item](./azdo_boards_work-item.md)

### ALIASES

Expand Down
18 changes: 18 additions & 0 deletions docs/azdo_boards_work-item.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
## Command `azdo boards work-item`

Work with Azure Boards work items.

### Available commands

* [azdo boards work-item list](./azdo_boards_work-item_list.md)

### Examples

```bash
# List work items in a project
azdo boards work-item list Fabrikam
```

### See also

* [azdo boards](./azdo_boards.md)
119 changes: 119 additions & 0 deletions docs/azdo_boards_work-item_list.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,119 @@
## Command `azdo boards work-item list`

```
azdo boards work-item list [ORGANIZATION/]PROJECT [flags]
```

List work items belonging to a project within an Azure DevOps organization.

This command builds and runs a WIQL query to obtain work item IDs and then fetches the
work item details in batches.


### Options


* `--area` `strings`

Filter by area path (repeatable); prefix with Under: to include subtree (e.g., Under:Web/Payments)

* `-a`, `--assigned-to` `strings`

Filter by assigned-to identity (repeatable); supports emails, descriptors, and @me

* `--authored-by` `strings`

Alias for --created-by

* `--changed-after` `string`

Lower bound on System.ChangedDate (RFC3339, YYYY-MM-DD, or 'today')

* `-c`, `--classification` `strings`

Filter by severity classification (repeatable): 1 - Critical, 2 - High, 3 - Medium, 4 - Low

* `--created-after` `string`

Lower bound on System.CreatedDate (RFC3339, YYYY-MM-DD, or 'today')

* `--created-by` `strings`

Filter by creator identity (repeatable); supports email, descriptor, @me

* `--iteration` `strings`

Filter by iteration path (repeatable); prefix with Under: to include subtree (e.g., Under:Release 2025/Sprint 1)

* `-q`, `--jq` `expression`

Filter JSON output using a jq expression

* `--json` `fields`

Output JSON with the specified fields. Prefix a field with '-' to exclude it.

* `-L`, `--limit` `int` (default `50`)

Maximum number of results to return (>=1)

* `-p`, `--priority` `ints`

Filter by priority (repeatable): 1-4

* `--sort` `strings`

Sort by field with optional direction (repeatable): changed[:asc|:desc], created[:asc|:desc], id[:asc|:desc], state[:asc|:desc], title[:asc|:desc], assigned-to[:asc|:desc], type[:asc|:desc], tags[:asc|:desc]

* `--state` `strings`

Filter by exact workflow state name (repeatable; combines with --status)

* `-s`, `--status` `strings` (default `[open]`)

Filter by state category: open, closed, resolved, all (repeatable)

* `--tag` `strings`

Filter by tag (repeatable); items must contain all specified tags

* `-t`, `--template` `string`

Format JSON output using a Go template; see "azdo help formatting"

* `-T`, `--type` `strings`

Filter by work item type (repeatable)


### ALIASES

- `ls`
- `l`

### JSON Fields

`_links`, `commentVersionRef`, `fields`, `id`, `relations`, `rev`, `url`

### Examples

```bash
# List open work items for a project in the default organization
azdo boards work-item list Fabrikam

# List all work items assigned to you
azdo boards work-item list Fabrikam --assigned-to @me --status all

# Filter by work item type and priority
azdo boards work-item list Fabrikam --type "User Story" --priority 1 --priority 2

# Filter by area subtree
azdo boards work-item list Fabrikam --area Under:Web/Payments

# Export JSON
azdo boards work-item list Fabrikam --json id,fields
```

### See also

* [azdo boards work-item](./azdo_boards_work-item.md)
35 changes: 35 additions & 0 deletions docs/azdo_help_reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,41 @@ Aliases
ls, l
```

### `azdo boards work-item <command>`

Work with Azure Boards work items.

#### `azdo boards work-item list [ORGANIZATION/]PROJECT [flags]`

List work items belonging to a project.

```
--area strings Filter by area path (repeatable); prefix with Under: to include subtree (e.g., Under:Web/Payments)
-a, --assigned-to strings Filter by assigned-to identity (repeatable); supports emails, descriptors, and @me
--authored-by strings Alias for --created-by
--changed-after string Lower bound on System.ChangedDate (RFC3339, YYYY-MM-DD, or 'today')
-c, --classification strings Filter by severity classification (repeatable): 1 - Critical, 2 - High, 3 - Medium, 4 - Low
--created-after string Lower bound on System.CreatedDate (RFC3339, YYYY-MM-DD, or 'today')
--created-by strings Filter by creator identity (repeatable); supports email, descriptor, @me
--iteration strings Filter by iteration path (repeatable); prefix with Under: to include subtree (e.g., Under:Release 2025/Sprint 1)
-q, --jq expression Filter JSON output using a jq expression
--json fields[=*] Output JSON with the specified fields. Prefix a field with '-' to exclude it.
-L, --limit int Maximum number of results to return (>=1) (default 50)
-p, --priority ints Filter by priority (repeatable): 1-4
--sort strings Sort by field with optional direction (repeatable): changed[:asc|:desc], created[:asc|:desc], id[:asc|:desc], state[:asc|:desc], title[:asc|:desc], assigned-to[:asc|:desc], type[:asc|:desc], tags[:asc|:desc]
--state strings Filter by exact workflow state name (repeatable; combines with --status)
-s, --status strings Filter by state category: open, closed, resolved, all (repeatable) (default [open])
--tag strings Filter by tag (repeatable); items must contain all specified tags
-t, --template string Format JSON output using a Go template; see "azdo help formatting"
-T, --type strings Filter by work item type (repeatable)
```

Aliases

```
ls, l
```

## `azdo co`

Alias for "pr checkout"
Expand Down
10 changes: 5 additions & 5 deletions internal/azdo/extensions/variablegroups.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,14 @@ type VariableValue struct {
}

// ToVariableValues converts a map of raw variable data into a slice of VariableValue structs.
func ToVariableValues(vars *map[string]interface{}) []VariableValue {
func ToVariableValues(vars *map[string]any) []VariableValue {
if vars == nil {
return nil
}
variables := make([]VariableValue, 0, len(*vars))
for name, val := range *vars {
v := VariableValue{Name: name}
if varMap, ok := val.(map[string]interface{}); ok {
if varMap, ok := val.(map[string]any); ok {
if isSecret, ok := varMap["isSecret"].(bool); ok {
v.IsSecret = isSecret
}
Expand All @@ -48,10 +48,10 @@ func ToVariableValues(vars *map[string]interface{}) []VariableValue {
}

// FromVariableValues converts a slice of VariableValue structs back into a map for API consumption.
func FromVariableValues(variables []VariableValue) *map[string]interface{} {
vars := make(map[string]interface{})
func FromVariableValues(variables []VariableValue) *map[string]any {
vars := make(map[string]any)
for _, v := range variables {
vars[v.Name] = map[string]interface{}{
vars[v.Name] = map[string]any{
"value": v.Value,
"isSecret": v.IsSecret,
}
Expand Down
Loading
Loading