Claim Step in GitLab Work Item
Claim a specific step in a GitLab work item's status table, assign it to the operator, and optionally link a merge request (MR). The step's status is set to `~"workflow::in dev"` and the assignee is updated to the operator's handle.
Editor's Note
The script requires a valid GitLab work item URL and step number. Ensure the operator has permission to edit the work item and that the step is not already assigned to another user. The `link-mr` command requires the MR IID to be provided.
When to Use It
- Claim a specific step in a GitLab work item for development
- Link a merge request to a step in a GitLab work item
- Show the current status table of a GitLab work item
SKILL.md
SkillsHunter provides this listing for informational purposes only. Review the skill’s source, license, and required permissions before use. You are responsible for deciding whether to install or run it. Terms of Use
---
name: claim-step
description: >
Claim a plan step in the status table of a GitLab work item, and link its
MR once it exists. Refuses only a step another user is assigned to, then sets the Assignee
cell to the operator's handle and the Status cell to
`~"workflow::in dev"`; later sets the MR cell. Use for "claim step 2",
"put me on step 4 of <work item url>", or "link the MR to the table".
`/run-step` calls it, so run it alone only to claim without implementing.
argument-hint: "<work item url> <step> | link-mr <work item url> <step> <mr iid>"
disable-model-invocation: true
---
# Claim a step
Run `scripts/claim-step.py` (stdlib Python, shells out to `glab api`). The
work item URL looks like
`https://gitlab.com/<project>/-/work_items/<iid>`; ask for it when
`$ARGUMENTS` has none.
| Need | Command |
| --- | --- |
| Show the rows | `claim-step.py show <url> [<step>]` |
| Check without writing | `claim-step.py claim <url> <step> --dry-run` |
| Claim | `claim-step.py claim <url> <step>` |
| Set the MR cell | `claim-step.py link-mr <url> <step> <mr iid>` |
Each prints one JSON object; read `status`:
- `ok`, `already_yours` (a no-op), `dry_run`: done.
- `not_unclaimed`: another user is the step's assignee. Report `row` and
stop. An empty Assignee is claimed whatever the Status says. Don't claim a different step unasked.
- `not_yours`, `mr_already_set`: `link-mr` refuses a row that isn't the
operator's or already names another MR. Report it.
- `no_table`, `no_step`, `bad_url`, `error`: report `message`.
- `verify_failed`: the row read back differently from what was written.
Report both rows and stop; someone edited the table at the same moment.
The write replaces the whole description, read just before it, so edits to
other rows survive unless they land in that moment.
## Rules
- `claim` and `link-mr` write to GitLab. Run them only when the operator
asked for that write in the current turn, or answered a question that named
it. `show` and `--dry-run` write nothing.
- The columns are found by header name: `#`, `MR`, `Status`, `Assignee`.
Other columns and their order don't matter, and only the target cell
changes.
- Claiming is not reversible from here. Clear a claim by hand in the table.
Community Reviews & Field Notes
Tried this skill on your own project? Share the model you used and the results you got.