Agent skill

Git::Repository Facade Methods

by ruby-git in ruby-git/ruby-git

Scaffolds and reviews facade methods on Git::Repository in ruby-git, with unit tests, integration tests and YARD documentation.

MITAuto-check passedDevelopment

Install Git::Repository Facade Methods

skills CLI
$ npx skills add ruby-git/ruby-git --skill facade-implementation -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install ruby-git/ruby-git facade-implementation --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/ruby-git/ruby-git.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.github/skills/facade-implementation .claude/skills/facade-implementation && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
facade-implementation
GitHub stars
1.8k
Token cost
~3.4k tokens
SKILL.md length
1,429 words
Files
2
Skills in repo
30
Repo updated
First seen
Licence
MIT

At a glance

Scaffolds and reviews facade methods on Git::Repository in ruby-git, with unit tests, integration tests and YARD documentation.

  • Works in 2 steps: Method name — the public Ruby method… → Git operation(s) — which…
  • Adding a new facade method to Git::Repository
  • SKILL.md covers Contents, How to use this skill, Related skills and Input, plus 3 more sections
  • Calls bundle

What it does

New facade methods on Git::Repository are scaffolded and existing ones reviewed for the ruby-git library. A facade method is the public entry point that orchestrates one or more Git::Commands classes, optionally pre-processes arguments and optionally parses output into Ruby return values, and the methods live in topic modules under lib/git/repository/.

You give a method name and the Git operations it wraps, plus the existing source, tests, command classes and parsers when updating or reviewing; if a command class is missing, it is scaffolded first through a companion skill. REFERENCE.md holds a checklist of the five facade responsibilities. The result is the method together with unit tests, integration tests and YARD docs, and related skills cover test conventions, YARD rules, RSpec standards and the project architecture.

When your agent uses it

  • Adding a new facade method to Git::Repository
  • Updating an existing facade method and its tests
  • Choosing or creating a topic module under lib/git/repository
  • Reviewing a facade method for correctness

Example prompts

  • “Using the Facade Implementation skill, scaffold Git::Repository::Staging#add.”
  • “Review Git::Repository::Committing#commit against the facade checklist.”
  • “Which topic module should a new stash_list facade method go in? Scaffold it with tests.”

Requirements

  • A checkout of the ruby-git repository
  • Ruby with RSpec for the tests

Workflow steps

2 steps, taken from the first numbered list in SKILL.md.

  1. Method name — the public Ruby method name (e.g. add, branch_list,
  2. Git operation(s) — which Git::Commands::* class(es) the method orchestrates.

What it can do on your machine

Read from SKILL.md and the folder at commit f3bf20f. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • bundle

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Links to these hosts (documentation or services it may open):

    • git-scm.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Git::Repository Facade Methods loads about 3.4k tokens when it runs. Until then it costs about 97 tokens; SKILL.md has 1,429 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~97
When it runs · the whole SKILL.md, loaded when a task matches
~3.4k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from ruby-git/ruby-git at commit f3bf20f, republished under its MIT licence (© ruby-git). 1,429 words, ~3,426 tokens.

Download SKILL.mdSave it as .claude/skills/facade-implementation/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.
name
facade-implementation
description
Scaffolds new and reviews existing Git::Repository facade methods (organized into Git::Repository::* topic modules) with unit tests, integration tests, and YARD docs. Use when adding a new facade method to Git::Repository, updating an existing facade method, choosing or creating a topic module under lib/git/repository/, or reviewing a facade method for correctness.

Facade Implementation

Scaffold new and review existing facade methods on Git::Repository. Facade methods live in topic modules under lib/git/repository/<topic>.rb (e.g. {Git::Repository::Staging}) and are included into the Git::Repository class.

A facade method is the public-API entry point that orchestrates one or more Git::Commands::* calls, optional argument pre-processing, and optional output parsing into rich Ruby return values. See The five facade responsibilities checklist for the responsibilities this layer is designed around.

Contents

How to use this skill

Attach this file to your Copilot Chat context, then invoke with the facade method to scaffold, update, or review. Examples:

text
Using the Facade Implementation skill, scaffold Git::Repository::Staging#add.
text
Facade Implementation review: Git::Repository::Committing#commit.

Input

The user provides:

  1. Method name — the public Ruby method name (e.g. add, branch_list, commit).
  2. Git operation(s) — which Git::Commands::* class(es) the method orchestrates. If the relevant command class does not exist yet, scaffold it first via Command Implementation.

Note: Git::Repository is intentionally empty during early phases of the redesign. Its initialize(execution_context:) constructor is introduced alongside the first facade method extraction; subsequent extractions only add new topic modules and include lines.

The agent then gathers:

Existing facade source

Read lib/git/repository.rb to see the include Git::Repository::<Topic> lines and which topic modules exist. List lib/git/repository/ to see all current topic modules and the facade methods they already define.

Skip when scaffolding into a brand-new topic module.

Existing facade tests

Read spec/unit/git/repository/<topic>_spec.rb and spec/integration/git/repository/<topic>_spec.rb (if present). Use as supplemental evidence of the existing test style before extending or reviewing.

Underlying command class(es)

Read lib/git/commands/<command>.rb for each command the facade method calls. The command's arguments do block defines the option keys the facade may forward, and the YARD @!method call block documents what each option does. The facade must not pass option keys the command does not declare.

Underlying parsers (if any)

Read lib/git/parsers/<parser>.rb for any parser the facade uses to transform command stdout into structured data.

Reference

See REFERENCE.md for the full reference covering:

  • Files to generate
  • Topic module selection (existing modules + decision rules for creating a new module)
  • Designing a facade method (return type, signature, body shape, failure state)
  • Topic module skeleton (file layout)
  • The five facade responsibilities as a checklist, plus the Git::SystemCallGuard rule for filesystem calls a facade method makes itself
  • Argument pre-processing patterns (path normalization, option whitelisting via SharedPrivate.assert_valid_opts! + private_constant, deprecation handling, defaults)
  • Internal helpers and encapsulation (sibling module_function modules under lib/git/repository/ instead of private methods on Git::Repository; bare-noun naming; growth path from SharedPrivate to responsibility-named modules)
  • When to call multiple commands (orchestration sequences)
  • When to use a parser vs. raw stdout
  • When to use a result-class factory method
  • Common failures (one-line delegation when orchestration is needed; leaking command-class types into the public API; bypassing the execution context; hardcoding policy options the caller cannot override)

Subagents load REFERENCE.md directly during the workflow steps that need it.

Workflow

This skill supports three modes. Determine which mode applies before starting:

  • Scaffold — adding a new facade method (and possibly a new topic module). Follow all steps.
  • Update — modifying an existing facade method (e.g. adding a new option to forward). Skip step 2 (module selection); steps 3a–3c are extending existing files rather than creating them.
  • Review — auditing an existing facade method (no changes). Follow all steps but produce findings instead of code.
  1. Gather input — collect the method name, target git operation(s), and any migration source per Input. Read the underlying command class(es) and parser(s) the method will call.

  2. Choose the topic module — load REFERENCE.md and apply Topic module selection:

    • Prefer extending an existing module under lib/git/repository/.
    • Create a new module only when the topic is recognizable — preferably matching a git-scm category (https://git-scm.com/docs) — and the methods would be awkward to place in any existing module. The deciding factor is topic fit, not method count; a single method that is genuinely distinct can start its own module.
    • New module names follow the three-tier convention: gerund (Staging, Logging, Diffing) for single-action modules; Noun + Operations (RemoteOperations, ObjectOperations) for mixed-bag modules; descriptive utility names (ContextHelpers, Maintenance) for cross-cutting helpers and housekeeping APIs. See REFERENCE.md §Naming a new topic module.
  3. For the facade method, repeat steps 3a–3e:

    a. Scaffold the facade method (subagent) (scaffold/update modes only) — delegate to a subagent: load REFERENCE.md and the Facade YARD Documentation skill, then create or extend lib/git/repository/<topic>.rb using the Designing a facade method section and Topic module skeleton. For new topic modules, also add the require and include lines to lib/git/repository.rb.

    Steps 3b and 3c may run in parallel (they produce independent files).

    b. Scaffold unit tests (subagent) (scaffold/update modes only) — delegate to a subagent: load Facade Test Conventions (which loads RSpec Unit Testing Standards), then create or extend spec/unit/git/repository/<topic>_spec.rb following the unit conventions (stub Git::Commands::* and Git::Parsers::* via instance_double; assert delegation contracts; cover each pre-processing branch).

    c. Scaffold integration tests (subagent) (scaffold/update modes only) — delegate to a subagent: load Facade Test Conventions, then create or extend spec/integration/git/repository/<topic>_spec.rb following the integration conventions (real git in a temp repository; assert end-to-end Ruby return value, not intermediate command results). Skip integration tests for true one-line delegators that add no orchestration on top of the underlying command — the command's own integration tests already cover that path.

    Steps 3d and 3e may run in parallel (they review independent file sets).

    d. Review Facade Tests (subagent) — delegate to a subagent: load and apply Facade Test Conventions against the unit and integration spec files. In scaffold/update modes, fix all findings and repeat until clean. In review mode, record findings only.

    e. Review YARD Documentation (subagent) — delegate to a subagent: load and apply Facade YARD Documentation against the topic module file. In scaffold/update modes, fix all findings and repeat until clean. In review mode, record findings only.

  4. Review facade shape and orchestration — load REFERENCE.md and verify against the Five facade responsibilities checklist, the Designing a facade method section, and Common failures. Confirm the method:

    • delegates to a Git::Commands::* class via @execution_context (never constructs commands with self or builds CLI argv directly)
    • does not return a Git::CommandLine::Result from the public contract unless that is the documented return type for the entire topic module
    • whitelists forwarded options when the caller's hash is opaque (per-method <METHOD>_ALLOWED_OPTS constant + SharedPrivate.assert_valid_opts!(allowed, **) — do not also slice; see Option whitelisting)
    • places each <METHOD>_ALLOWED_OPTS constant immediately before the method that uses it (not grouped at the top of the module)
    • handles defaults and deprecations explicitly, not by relying on command internals
    • is explicitly classified as legacy-contract (legacy predecessor exists) or 5.x-native (new facade API), and signature shape matches that classification (why the call shape is preserved: ADR-0005)
    • has tests that verify call-shape compatibility when classification is legacy-contract (positional hash and/or keyword-arg / **opts forms where required)
    • follows the Failure state rules where they apply: a method that checks out a branch and switches back runs the restore checkout only on success and has both SharedPrivate guards, and any method the rules cover has a @note that says what a failure leaves behind
  5. Run quality gates — discover the prerequisite tasks for default and run them sequentially, fixing failures before advancing:

    bash
    bundle exec ruby -e "require 'rake'; load 'Rakefile'; puts Rake::Task['default'].prerequisites"

    Run each listed task individually in order via bundle exec rake <task> (one task per invocation). On failure, fix the issue and re-run that same task. Continue until every task passes on its first attempt with no fixes needed.

Show full SKILL.md (152 more words)Show less

Output

For scaffold and update modes, produce:

  1. Topic module — lib/git/repository/<topic>.rb (created or extended)
  2. Facade wiring — lib/git/repository.rb updated with require and include when a new topic module was created
  3. Unit tests — spec/unit/git/repository/<topic>_spec.rb
  4. Integration tests — spec/integration/git/repository/<topic>_spec.rb (omit only for true one-line delegators)
  5. All quality gates pass — rspec, minitest, rubocop, and yard all green

For review mode, produce:

CheckStatusIssue
Topic module placementPass/Fail...
Orchestration via @execution_contextPass/Fail...
Argument pre-processing completePass/Fail...
Option whitelisting (where required)Pass/Fail...
*_ALLOWED_OPTS placed immediately before its methodPass/Fail...
Signature classification documentedPass/Fail...
Signature shape matches classificationPass/Fail...
Return value matches documented contractPass/Fail...
Parser/result-class wiring correctPass/Fail...
Failure state (HEAD restore, guards, @note)Pass/Fail...
YARD docs completePass/Fail...
Unit + integration coveragePass/Fail...

Then list required fixes.

Branch workflow: Implement scaffolding or updates on a feature branch. Never commit or push directly to main — open a pull request when changes are ready to merge.

© ruby-git, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 1 other file in .github/skills/facade-implementation of ruby-git/ruby-git.

  • SKILL.md
  • REFERENCE.md

Open the folder on GitHubat commit f3bf20f

Compare with similar skills

Git::Repository Facade Methods next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Git::Repository Facade Methods compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Git::Repository Facade Methods this skillruby-git/ruby-git1.8k—~3.4kAutomated safety check: PassMIT
Leetcode Pywislertt/leetcode-py142—~1.4kAutomated safety check: PassApache-2.0
Research Initbrycewang-stanford/Auto-Empirical-Research-Skills4.5k—~839Automated safety check: PassCustom licence
Adk Setupgoogle/adk-python22k—~993Automated safety check: NotesApache-2.0
Gapgraph-robots/graph-as-policy155—~3.3kAutomated safety check: PassMIT
Score Harnessruvnet/metaharness688—~613Automated safety check: PassMIT

Similar skills

  • Leetcode Py

    wislertt/leetcode-py

    Generates Python LeetCode practice environments and manages a 307-problem catalog with the lcpy CLI.

    142 GitHub stars~1.4k tokensUpdated today
    Business, Finance & HRAuto-check passed
  • Research Init

    brycewang-stanford/Auto-Empirical-Research-Skills

    Scaffold a new research project with full reproducibility infrastructure in R and/or Python.

    4.5k GitHub stars~839 tokensUpdated 2 days ago
    DevelopmentAuto-check passed
  • Adk Setup

    google/adk-python

    Official

    Sets up a local ADK Python development environment in a git clone of the open-source adk-python repository: a uv virtual environment, all dependency extras, pre-commit hooks, and a first unit-test…

    22k GitHub stars~993 tokensUpdated today
    DevelopmentAuto-check: notes
  • Gap

    graph-robots/graph-as-policy

    Program robots with GaP (graph-as-policy) — compile natural-language tasks into typed, verified robot skill graphs and run them on simulators or real robots.

    155 GitHub stars~3.3k tokensUpdated 7 days ago
    DevelopmentAuto-check passed
  • Score Harness

    ruvnet/metaharness

    5-dimension scorecard (0-100, grade A/B/C/F) for a scaffolded harness.

    688 GitHub stars~613 tokensUpdated today
    DevelopmentAuto-check passed
  • Official

    Detects duplicate boilerplate, copy-paste tests, and structural maintainability issues across .NET test suites.

    5.6k GitHub starsUsed in 1 repo~2.5k tokens
    DevelopmentAuto-check passed

More from ruby-git/ruby-git

All 30 skills in this repo
  • Addresses unresolved pull request review threads and suppressed (low-confidence) Copilot review comments on the current branch, folds each fix into the…

    1.8k GitHub stars~657 tokensUpdated 5 days ago
    Auto-check passed
  • Breaking Change Analysis

    ruby-git/ruby-git

    Assesses what an API change would break before it is made, finds every usage, documents the impact and plans a deprecation or migration path.

    1.8k GitHub stars~1.7k tokensUpdated 5 days ago
    Auto-check passed
  • Diagnoses and fixes failing GitHub Actions runs by identifying the failure, fetching only the relevant logs, finding the root cause and reproducing it locally.

    1.8k GitHub stars~1.9k tokensUpdated 5 days ago
    Auto-check passed
  • Scaffolds and reviews `Git::Commands::*` classes in the ruby-git library, with unit tests, integration tests and YARD docs, using the Base command architecture.

    1.8k GitHub stars~3k tokensUpdated 5 days ago
    Auto-check passed
  • Gem Dependency Management

    ruby-git/ruby-git

    Workflow for updating gem dependencies and fixing CVEs in the ruby-git project: assess with bundle outdated and audit, edit the gemspec, test, then commit with conventional messages.

    1.8k GitHub stars~806 tokensUpdated 5 days ago
    Auto-check passed
  • Migrates a direct command call in Ruby Git's Git::Lib to a Git::Commands class, as part of a Strangler Fig redesign, with a plan, legacy tests and a pull request.

    1.8k GitHub stars~4.4k tokensUpdated 5 days ago
    Auto-check passed

Works with

Questions about Git::Repository Facade Methods

What does Git::Repository Facade Methods do?

Scaffolds and reviews facade methods on Git::Repository in ruby-git, with unit tests, integration tests and YARD documentation. New facade methods on Git::Repository are scaffolded and existing ones reviewed for the ruby-git library. A facade method is the public entry point that orchestrates one or more Git::Commands classes, optionally pre-processes arguments and optionally parses output into Ruby return values, and the methods live in topic modules under lib/git/repository/.

When should I use Git::Repository Facade Methods?

Git::Repository Facade Methods fits situations like: adding a new facade method to Git::Repository; updating an existing facade method and its tests; choosing or creating a topic module under lib/git/repository; reviewing a facade method for correctness.

How do I install Git::Repository Facade Methods in Claude Code?

Run `npx skills add ruby-git/ruby-git --skill facade-implementation -a claude-code`. Or copy the skill folder (.github/skills/facade-implementation in ruby-git/ruby-git) into .claude/skills/facade-implementation in your project. Claude Code loads it when a task matches its description.

How do I install Git::Repository Facade Methods in Codex?

Run `npx skills add ruby-git/ruby-git --skill facade-implementation -a codex`. Or copy the skill folder (.github/skills/facade-implementation in ruby-git/ruby-git) into .agents/skills/facade-implementation in your project. Codex loads it when a task matches its description.

Can I use Git::Repository Facade Methods in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add ruby-git/ruby-git --skill facade-implementation -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/facade-implementation, .gemini/skills/facade-implementation, .github/skills/facade-implementation and .opencode/skills/facade-implementation in your project.

What does Git::Repository Facade Methods need to run?

Going by SKILL.md and its folder, Git::Repository Facade Methods needs the command-line tools its instructions call (bundle). Our summary lists: A checkout of the ruby-git repository; Ruby with RSpec for the tests.

Does Git::Repository Facade Methods access the network?

SKILL.md names 1 domain. As links in the text: git-scm.com. This is read from the text; nothing was executed.

Is Git::Repository Facade Methods safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Git::Repository Facade Methods use?

Git::Repository Facade Methods is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Git::Repository Facade Methods use?

About 3.4k tokens (SKILL.md is roughly 14k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Git::Repository Facade Methods?

Skills that share tags, products or a category with Git::Repository Facade Methods: Leetcode Py (wislertt/leetcode-py, 142 stars), Research Init (brycewang-stanford/Auto-Empirical-Research-Skills, 4.5k stars), Adk Setup (google/adk-python, 22k stars) and Gap (graph-robots/graph-as-policy, 155 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Git::Repository Facade Methods?

ruby-git (a GitHub organization) maintains it in ruby-git/ruby-git, which has 1,799 GitHub stars. The repository holds 30 skills in this directory. The repository was last updated on October 2, 2026.

Source: ruby-git/ruby-git on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.