Get the FREE Ultimate OpenClaw Setup Guide →

gitlab-assistant

npx machina-cli add skill grandcamel/GitLab-Assistant-Skills/gitlab-assistant --openclaw
Files (1)
SKILL.md
9.7 KB

GitLab Assistant

Central hub for GitLab automation using the glab CLI. Routes requests to the most appropriate specialized skill.

Quick Reference

I want to...Use this skillRisk
Work with merge requestsgitlab-mr⚠️
Work with issuesgitlab-issue⚠️
Check/run CI pipelinesgitlab-ci⚠️
Clone/fork/create reposgitlab-repo⚠️
Manage releasesgitlab-release⚠️
Manage labelsgitlab-label⚠️
Manage milestonesgitlab-milestone⚠️
Manage CI/CD variablesgitlab-variable⚠️
Manage groups/teamsgitlab-group⚠️
Search GitLabgitlab-search-
Protect branchesgitlab-protected-branch⚠️
Manage webhooksgitlab-webhook⚠️
Repository file operationsgitlab-file⚠️
Manage wiki pagesgitlab-wiki⚠️
MR/Issue discussionsgitlab-discussion⚠️
Project badgesgitlab-badge⚠️
Container registrygitlab-container⚠️⚠️
Security vulnerabilitiesgitlab-vulnerability⚠️

Risk Legend: - Safe | ⚠️ Caution | ⚠️⚠️ Warning | ⚠️⚠️⚠️ Danger

Routing Rules

Rule 1: Explicit Resource Type

Route based on the GitLab resource being worked with:

KeywordsRoute to
MR, merge request, pull request, review, approve, mergegitlab-mr
issue, bug, ticket, task, feature requestgitlab-issue
CI, CD, pipeline, build, job, deploy, artifactsgitlab-ci
repo, repository, project, clone, forkgitlab-repo
release, tag, version, changeloggitlab-release
label, tag (for issues/MRs)gitlab-label
milestone, sprint, iterationgitlab-milestone
variable, secret, env, CI variablegitlab-variable
group, team, organization, members, namespacegitlab-group
search, find, query (global/group/project)gitlab-search
protect branch, branch protection, access rulesgitlab-protected-branch
webhook, hook, notification callback, integrationgitlab-webhook
file, blob, content, raw (repository files)gitlab-file
wiki, documentation pagegitlab-wiki
discussion, thread, comment, note, replygitlab-discussion
badge, status badge, coverage badgegitlab-badge
container, registry, docker, image, tag (container)gitlab-container
vulnerability, security, scan, CVE, SAST, DASTgitlab-vulnerability

Rule 2: Common Workflows

WorkflowSkills Involved
Code reviewgitlab-mr (checkout, review, approve, merge)
Bug trackinggitlab-issue (create, assign, close)
Deploymentgitlab-ci (run, status, artifacts)
Release processgitlab-release + gitlab-ci
Project setupgitlab-repo (create, clone)

Rule 3: Multi-Step Operations

For complex workflows that span multiple skills, coordinate them:

Example: "Release version 1.2.0"
1. gitlab-mr: Ensure all MRs are merged
2. gitlab-ci: Verify pipeline passes
3. gitlab-release: Create release with changelog

Skills Overview

gitlab-mr (Merge Requests)

  • Purpose: Create, review, approve, and merge MRs
  • Key commands: glab mr list, glab mr create, glab mr checkout, glab mr merge
  • Risk: ⚠️ (merge is destructive)
  • Triggers: MR, merge request, review, approve, merge, checkout

gitlab-issue (Issues)

  • Purpose: Track bugs, features, and tasks
  • Key commands: glab issue list, glab issue create, glab issue close
  • Risk: ⚠️ (close/delete are destructive)
  • Triggers: issue, bug, task, ticket, feature

gitlab-ci (CI/CD Pipelines)

  • Purpose: View, trigger, and manage CI/CD pipelines
  • Key commands: glab ci status, glab ci view, glab ci run, glab ci artifact
  • Risk: ⚠️ (run triggers compute resources)
  • Triggers: CI, pipeline, build, job, deploy, artifacts, lint

gitlab-repo (Repositories)

  • Purpose: Clone, fork, create, and manage repositories
  • Key commands: glab repo clone, glab repo fork, glab repo create
  • Risk: ⚠️⚠️ (delete is highly destructive)
  • Triggers: repo, repository, project, clone, fork

gitlab-release (Releases)

  • Purpose: Create and manage releases
  • Key commands: glab release create, glab release list, glab release view
  • Risk: ⚠️ (creates tags and releases)
  • Triggers: release, version, changelog, tag

gitlab-label (Labels)

  • Purpose: Manage project labels
  • Key commands: glab label create, glab label list
  • Risk: ⚠️ (affects issue/MR categorization)
  • Triggers: label, tag (for categorization)

gitlab-milestone (Milestones)

  • Purpose: Manage project milestones
  • Key commands: glab milestone create, glab milestone list
  • Risk: ⚠️ (affects planning)
  • Triggers: milestone, sprint, iteration

gitlab-variable (CI/CD Variables)

  • Purpose: Manage CI/CD variables and secrets
  • Key commands: glab variable set, glab variable list
  • Risk: ⚠️⚠️ (contains secrets)
  • Triggers: variable, secret, env var, CI variable

gitlab-group (Groups - API)

  • Purpose: Manage groups, members, subgroups via API
  • Key commands: glab api groups, glab api groups/:id/members
  • Risk: ⚠️ (group management)
  • Triggers: group, team, organization, members, namespace

gitlab-search (Search - API)

  • Purpose: Search across GitLab (projects, issues, code, etc.)
  • Key commands: glab api "search?scope=...&search=..."
  • Risk: - (read-only)
  • Triggers: search, find, query

gitlab-protected-branch (Protected Branches - API)

  • Purpose: Manage branch protection rules
  • Key commands: glab api projects/:id/protected_branches
  • Risk: ⚠️ (affects branch access)
  • Triggers: protect branch, branch protection, access rules

gitlab-webhook (Webhooks - API)

  • Purpose: Manage project webhooks
  • Key commands: glab api projects/:id/hooks
  • Risk: ⚠️ (external integrations)
  • Triggers: webhook, hook, notification, integration

gitlab-file (Repository Files - API)

  • Purpose: Read/write repository files via API
  • Key commands: glab api projects/:id/repository/files/:path
  • Risk: ⚠️ (modifies files)
  • Triggers: file, blob, content, raw

gitlab-wiki (Wiki - API)

  • Purpose: Manage project wiki pages
  • Key commands: glab api projects/:id/wikis
  • Risk: ⚠️ (documentation changes)
  • Triggers: wiki, documentation page

gitlab-discussion (Discussions - API)

  • Purpose: Manage threaded discussions on MRs/issues
  • Key commands: glab api projects/:id/merge_requests/:iid/discussions
  • Risk: ⚠️ (comments)
  • Triggers: discussion, thread, comment, note, reply

gitlab-badge (Badges - API)

  • Purpose: Manage project badges
  • Key commands: glab api projects/:id/badges
  • Risk: ⚠️ (project display)
  • Triggers: badge, status badge, coverage badge

gitlab-container (Container Registry - API)

  • Purpose: Manage container registry images and tags
  • Key commands: glab api projects/:id/registry/repositories
  • Risk: ⚠️⚠️ (delete images is destructive)
  • Triggers: container, registry, docker, image

gitlab-vulnerability (Vulnerabilities - API)

  • Purpose: Manage security vulnerabilities (Ultimate)
  • Key commands: glab api projects/:id/vulnerabilities
  • Risk: ⚠️ (security state changes)
  • Triggers: vulnerability, security, scan, CVE

Connection Verification

Before any operation, verify GitLab is configured:

glab auth status

If not authenticated:

glab auth login

Check current repository context:

glab repo view

Common glab Commands Quick Reference

# Authentication
glab auth login              # Interactive login
glab auth status             # Check auth status

# Merge Requests
glab mr list                 # List MRs
glab mr create               # Create MR
glab mr view <id>            # View MR details
glab mr checkout <id>        # Checkout MR branch
glab mr merge <id>           # Merge MR

# Issues
glab issue list              # List issues
glab issue create            # Create issue
glab issue view <id>         # View issue
glab issue close <id>        # Close issue

# CI/CD
glab ci status               # Current pipeline status
glab ci view                 # Interactive pipeline view
glab ci run                  # Trigger pipeline
glab ci artifact             # Download artifacts

# Repository
glab repo clone <path>       # Clone repository
glab repo fork <path>        # Fork repository
glab repo view               # View repo info

Disambiguation

When request is ambiguous, ask for clarification:

Ambiguous RequestClarifying Question
"Show me the status""Do you want CI pipeline status (glab ci status) or MR status (glab mr list)?"
"Create a new one""What would you like to create? An issue, MR, or repository?"
"List everything""What would you like to list? MRs, issues, pipelines, or repos?"

Related Documentation

Source

git clone https://github.com/grandcamel/GitLab-Assistant-Skills/blob/main/skills/gitlab-assistant/SKILL.mdView on GitHub

Overview

GitLab Assistant acts as a central hub for GitLab automation using the glab CLI. It routes requests to the most appropriate specialized skill (e.g., gitlab-mr, gitlab-issue) and coordinates multi-step workflows. Start here for any GitLab task to ensure the right tool handles it.

How This Skill Works

It uses GitLab resource keywords to route the task to a specialized skill (MR to gitlab-mr, issues to gitlab-issue). For multi-step processes, it sequences the relevant skills (gitlab-mr, gitlab-ci, gitlab-release) to complete the task using the glab CLI under the hood.

When to Use It

  • You want to work with a Merge Request (MR)
  • You need to manage issues
  • You need to run or check CI pipelines
  • You must clone, fork, or create a repo
  • You’re unsure which skill fits or you have a multi-step GitLab workflow

Quick Start

  1. Step 1: Describe the GitLab task with a clear resource type (MR, issue, CI, repo, etc.).
  2. Step 2: Let gitlab-assistant route to the appropriate skill (e.g., gitlab-mr, gitlab-issue) and perform actions via glab.
  3. Step 3: Review results; if needed, continue with additional steps or adjust scope.

Best Practices

  • Clearly specify the resource and action (MR, issue, CI, etc.).
  • Provide explicit steps for multi-step tasks to keep routing deterministic.
  • Validate destructive actions in a test project before applying to production.
  • Include enough context (project, namespace, MR/issue numbers) to avoid ambiguity.
  • Ensure proper permissions and avoid exposing sensitive data in prompts.

Example Use Cases

  • Create and review an MR, then merge after approval.
  • Create an issue, assign it to a teammate, and set a due date.
  • Trigger a CI pipeline, monitor its status, and retrieve artifacts if successful.
  • Coordinate a release by creating a release entry after all MRs are merged and CI passes.
  • Update or add a webhook to integrate an external service with the project.

Frequently Asked Questions

Add this skill to your agents
Sponsor this space

Reach thousands of developers