Skip to content

isamisushi/glab-skill

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

glab-skill

A Codex skill for working with GitLab through the glab CLI.

This repository packages a reusable skill that tells Codex when to prefer glab, how to verify command availability, and which local references to consult before guessing flags.

What This Includes

  • skills/glab/SKILL.md: the skill definition and operating rules
  • skills/glab/agents/openai.yaml: agent metadata for invocation UX
  • skills/glab/references/: checked-in command references derived from glab docs and help output
  • skills/glab/scripts/generate_docs_command_tree.py: regeneration script for the reference files

Why This Exists

glab is broad, changes over time, and has many subcommands that are easy to guess wrong. This skill pushes the agent toward a stricter workflow:

  1. confirm repo and auth context
  2. check source-derived references or local help
  3. prefer a built-in glab subcommand over glab api
  4. keep commands non-interactive and scriptable

That is the difference between a demo prompt and something you can rely on in real repositories.

Requirements

  • Codex with local skill support
  • glab installed and authenticated
  • git available in PATH
  • python3 available if you want to regenerate references

Install

Clone this repository somewhere local, then copy skills/glab into the skill directory used by your coding agent.

Source directory:

skills/glab

Target directories:

  • Codex / Cursor: .agents/skills/glab
  • Claude Code: .claude/skills/glab

Example:

git clone git@github.com:isamisushi/glab-skill.git

# Codex / Cursor
mkdir -p ~/.agents/skills
cp -R glab-skill/skills/glab ~/.agents/skills/glab

# Claude Code
mkdir -p ~/.claude/skills
cp -R glab-skill/skills/glab ~/.claude/skills/glab

The skill is self-contained. The references it depends on are already checked in.

Usage

Ask the agent to use the glab skill, or rely on implicit invocation when the task is clearly about GitLab state.

Example prompts:

  • Use the glab skill to list my open merge requests
  • Use the glab skill to show the latest failed pipeline
  • Use the glab skill to create a release for tag v1.2.3
  • Use the glab skill to fetch project variables with glab api

Updating References

The checked-in reference files are snapshots. They should be regenerated after upgrading glab or when the GitLab CLI command surface changes.

From the repository root:

python3 skills/glab/scripts/generate_docs_command_tree.py

The script expects working glab authentication because it queries GitLab and clones the upstream CLI repository.

After regeneration, review and commit the updated files under skills/glab/references/.

Scope

This repository is intentionally narrow. It is not a general GitLab integration layer, a plugin marketplace package, or a wrapper around glab itself. It is a skill bundle that improves command selection and reduces hallucinated CLI usage.

Contributing

See CONTRIBUTING.md.

License

MIT. See LICENSE.

About

A reusable AI agent skill for working with GitLab through the glab CLI, with checked-in command references and a stricter non-guessing workflow.

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages