Skip to main content
Glama
onesmartguy

Agentic Bits Claude Plugin

by onesmartguy

get_branch_status

Check current git branches across configured repositories to monitor development status and manage repository visibility.

Instructions

Return the current git branch for every configured repo. Respects the enabled flag and showReferenceRepos toggle.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function for the `get_branch_status` tool, which retrieves git branch info for configured repositories based on status bar settings.
    server.tool(
      "get_branch_status",
      "Return the current git branch for every configured repo. Respects the enabled flag and showReferenceRepos toggle.",
      {},
      async () => {
        const config = loadConfig();
        if (!config.statusbar.enabled) {
          return { content: [{ type: "text", text: "Status bar is disabled. Use toggle_statusbar to enable it." }] };
        }
        const visible = config.repos.filter((r) => {
          if (!r.show) return false;
          if (r.type === "reference" && !config.statusbar.showReferenceRepos) return false;
          return true;
        });
        const branches = getAllBranchInfo(visible);
        const lines = branches.map((b) => {
          const tag = b.type === "reference" ? " [ref]" : "";
          const status = b.error ? `ERROR: ${b.error}` : (b.branch ?? "HEAD detached");
          return `${b.label}${tag}: ${status}`;
        });
        const statusLine = formatStatusLine(branches, config.statusbar.showReferenceRepos);
        return {
          content: [
            { type: "text", text: lines.join("\n") || "(no visible repos)" },
            { type: "text", text: `\nStatus line preview:\n${statusLine}` },
          ],
        };
      }
  • Registration of the `get_branch_status` tool within the McpServer instance.
    server.tool(
      "get_branch_status",
      "Return the current git branch for every configured repo. Respects the enabled flag and showReferenceRepos toggle.",
      {},

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/onesmartguy/agentic-bits-claude-plugin'

If you have feedback or need assistance with the MCP directory API, please join our Discord server