mr-assign
Skill2 starsChanged 41 days agoMITView on GitHub
Assign GitLab merge request to developer using shortcuts. Run only when the user explicitly asks for it.
We split this skill into the rules it gives an agent
14 rules. About 0 are common, 9 are distinctive, and 5 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈9
Distinctive · estimate
This author's own choices. Worth a look.
5
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 79
Resolve developer: Look up GitLab username from shortcut
- Distinctive: line 80
Fetch MR: Verify MR exists and get current state
- Very specific: line 166
Add entry to developers section:
- Very specific: line 177
Use shortcut in /mr-assign or /mr-create
- Distinctive: line 227
Must ask before making assignment
- Distinctive: line 232
Check spelling of shortcut
- Very specific: line 233
Verify developer exists in .claude/gitlab-config.json
- Distinctive: line 234
Use exact GitLab username if shortcut not defined
- Distinctive: line 237
Verify MR number is correct
- Distinctive: line 238
Check you have access to the project
- Very specific: line 239
Ensure MR is in <PROJECT_PATH> project
- Very specific: line 244
Check token in ~/.config/glab-cli/config.yml
- Distinctive: line 248
Ask project maintainer to add them
- Distinctive: line 249
Verify username is correct
≈ “Common” is an estimate: at least 1 in 5 of the 308,232 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
/mr-assign
Project resolution (project-agnostic)
This command works in any GitLab repo — nothing here is tied to a specific project. Resolve the target at runtime:
- Instance, project path, and IDs — auto-detected by
glabfrom the current repo's git remotes; never hardcode them.glabreadsorigin/upstreamdirectly. When a numeric id is needed:glab api projects/$(git remote get-url origin | sed -E 's#^[a-z]+://[^/]+/##; s#^.*@[^:]+:##; s#\.git$##' | sed 's#/#%2F#g') | jq -r '.id' - Fork vs single-repo — if both
originandupstreamremotes exist, treatoriginas your fork (push target) andupstreamas the MR/issue target; otherwise operate onorigin. - Optional extras — if
.claude/gitlab-config.jsonexists in the current repo, loaddevelopers(assignee/reviewer shortcuts) andlabels(auto-label rules) from it. If it is absent, those features degrade gracefully: ask the user for the assignee/reviewer/labels instead of resolving a shortcut.
All URLs, namespaces, and IDs in the examples below (
<GITLAB_URL>,<PROJECT_PATH>,projects/<FORK_ID>, etc.) are illustrative placeholders — resolve real values per the steps above.
Assigns a GitLab merge request to a developer using shortcut names or GitLab usernames.
⚠️ Important: This command sets the ASSIGNEE (person responsible for taking action), NOT the reviewer. For code review requests, use /mr-review-request instead.
⚠️ Permission Required: This command will ask for user confirmation before assigning the MR.
Assignee vs Reviewer - Quick Guide
Use /mr-assign when:
- ✅ Someone needs to take ownership of the MR
- ✅ Someone needs to merge the MR
- ✅ Someone needs to fix issues before merging
- ✅ Transferring responsibility to another developer
Use /mr-review-request when:
- ✅ Someone should review and approve the code
- ✅ You need feedback on your implementation
- ✅ Requesting code review from team members
Example Workflow:
# 1. Create MR and request reviews from team
/mr-create alice bob
# 2. If alice needs to merge it, assign to him
/mr-assign 1598 alice
# 3. If more reviews needed later
/mr-review-request 1598 carolUsage
/mr-assign <mr-number> <developer>Arguments:
<mr-number>- MR number (e.g.,1598or!1598)<developer>- Developer shortcut or GitLab username
Developer Shortcuts: resolved from the optional .claude/gitlab-config.json → developers map in the current repo. If no config file exists, pass a real GitLab username directly. Resolve a username to an id with glab api "users?username=<name>" | jq '.[0].id'.
Examples:
/mr-assign 1598 alice # Assign MR !1598 to alice
/mr-assign !1598 bob # Assign MR !1598 to bob
/mr-assign 1598 carol # Assign MR !1598 to carol
/mr-assign 1598 dana # Assign MR !1598 to dana.leeWhat it does
- Resolves developer shortcut to GitLab username
- Fetches MR details to verify it exists
- Asks user for permission to assign
- Assigns MR to developer via GitLab API
- Confirms assignment
Process
- Parse arguments: Extract MR number and developer shortcut
- Resolve developer: Look up GitLab username from shortcut
- Fetch MR: Verify MR exists and get current state
- ⚠️ ASK USER PERMISSION: Display assignment preview and await confirmation
- Assign MR (if approved): PUT to
/api/v4/projects/2/merge_requests/{iid} - Confirm: Display updated MR assignee
Example Output
Example 1: Assign using shortcut
🔍 Fetching MR !1598...
📋 MR #1598: feat(shipments): add pickup details to API responses
Status: Open
Author: dana.lee
Current assignee: None
👤 Resolving developer shortcut: alice → alice
⚠️ Assign MR !1598 to alice? (yes/no)
> yes
✓ Assigning MR...
✓ MR !1598 assigned to alice
🔗 MR URL: <GITLAB_URL>/<PROJECT_PATH>/-/merge_requests/1598Example 2: Re-assign to different developer
🔍 Fetching MR !1598...
📋 MR #1598: feat(shipments): add pickup details to API responses
Status: Open
Author: dana.lee
Current assignee: alice
👤 Resolving developer shortcut: bob → bob
⚠️ Change assignee from alice to bob? (yes/no)
> yes
✓ Assigning MR...
✓ MR !1598 reassigned to bobExample 3: User cancels
🔍 Fetching MR !1598...
📋 MR #1598: feat(shipments): add pickup details to API responses
⚠️ Assign MR !1598 to carol? (yes/no)
> no
✗ Assignment cancelledDeveloper Management
Available Developers
Developers are defined in .claude/gitlab-config.json:
{
"developers": {
"alice": {
"username": "alice",
"name": "Alice"
},
"bob": {
"username": "bob",
"name": "Bob"
},
"carol": {
"username": "carol",
"name": "Carol"
},
"dana": {
"username": "dana.lee",
"name": "Dana Lee"
}
}
}Adding New Developers
To add a new developer:
- Edit
.claude/gitlab-config.json - Add entry to
developerssection:"shortcut_name": { "shortcut": "shortcut_name", "username": "gitlab_username", "name": "Full Name", "gitlab_user_id": null, "email": null } - Save file
- Use shortcut in
/mr-assignor/mr-create
Finding GitLab Usernames
# Search for a user
glab api users?search=name | jq -r '.[] | {username, name}'
# Get specific user details
glab api users/username | jq -r '{id, username, name, email}'GitLab API
Endpoint: PUT /api/v4/projects/{id}/merge_requests/{iid}
Parameters:
{
"assignee_ids": [user_id]
}Example API call:
# Get user ID
glab api users?username=alice | jq -r '.[0].id'
# Assign MR
glab api --method PUT projects/2/merge_requests/1598 \
-F assignee_ids[]=<user_id>Multiple Assignees
To assign multiple developers:
/mr-assign 1598 alice bobThis will assign both alice and bob to the MR.
Permissions
Requires user permission because:
- Changes MR state
- Affects who receives notifications
- May trigger workflows
Per GITLAB_PERMISSIONS.md:
assign:mris inrequiresPermissionlist- Must ask before making assignment
Troubleshooting
"Developer not found"
- Check spelling of shortcut
- Verify developer exists in
.claude/gitlab-config.json - Use exact GitLab username if shortcut not defined
"MR not found"
- Verify MR number is correct
- Check you have access to the project
- Ensure MR is in
<PROJECT_PATH>project
"Permission denied"
- Your GitLab token needs
apiscope - You must have Developer role or higher
- Check token in
~/.config/glab-cli/config.yml
"User does not have access to project"
- Developer must be a member of
<PROJECT_PATH>project - Ask project maintainer to add them
- Verify username is correct
Related Commands
/mr-create [dev]- Create MR and assign in one command/mr-create --assignee <dev>- Create MR with assignee- View
.claude/core/GITLAB_PERMISSIONS.mdfor permission rules
Notes
- Assigning clears previous assignee (use multiple names for multiple assignees)
- Assignee receives email notification
- Can assign yourself using
danashortcut - Works with both open and draft MRs
Created: 2025-12-27
Last updated: 2025-12-27
Config file: .claude/gitlab-config.json
Other versions1 project uses a version of this.
Word for word · 1
- AhmedMerza/claude-skills★ 2100% same
Edited · 0
None found.
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository53 other files it gives its agents.
- animateSkill
- api-docs-completeSkill
- best-optionSkill
- browseSkill
- changelog-generateSkill
- checkpointSkill
- claimSkill
- commitSkill
- courtSkill
- design-driftSkill
- designSkill
- expandSkill
- explainSkill
- fix-reviewSkill
- grill-meSkill
- handover-listSkill
- handover-resumeSkill
- handover-saveSkill
- i18n-syncSkill
- issueSkill
- leadSkill
- mr-approveSkill
- mr-createSkill
- mr-guideSkill
- mr-listSkill
- mr-mergeSkill
- mr-review-requestSkill
- mr-reviewSkill
- mr-statusSkill
- persona-walkthroughSkill
- ponytailSkill
- prove-the-testSkill
- qa-crawlSkill
- qa-sweepSkill
- reflectSkill
- reviewSkill
- root-causeSkill
- scoutSkill
- second-opinionSkill
- ship-checkSkill
- skill-auditSkill
- skill-compareSkill
- spinoffSkill
- story-siteSkill
- tool-compareSkill
- ui-auditSkill
- ui-polishSkill
- usage-weekSkill
- ux-auditSkill
- validate-planSkill
- video-teardownSkill
- wait-whatSkill
- where-were-weSkill
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

