@cyanheads/git-mcp-server
Version:
An MCP (Model Context Protocol) server enabling LLMs and AI agents to interact with Git repositories. Provides tools for comprehensive Git operations including clone, commit, branch, diff, log, status, push, pull, merge, rebase, worktree, tag management,
45 lines • 1.56 kB
TypeScript
/**
* @fileoverview Defines the core logic, schemas, and types for the git_set_working_dir tool.
* @module src/mcp-server/tools/gitSetWorkingDir/logic
*/
import { z } from "zod";
import { type RequestContext } from "../../../utils/index.js";
export declare const GitSetWorkingDirInputSchema: z.ZodObject<{
path: z.ZodString;
validateGitRepo: z.ZodDefault<z.ZodBoolean>;
initializeIfNotPresent: z.ZodDefault<z.ZodBoolean>;
}, "strip", z.ZodTypeAny, {
path: string;
validateGitRepo: boolean;
initializeIfNotPresent: boolean;
}, {
path: string;
validateGitRepo?: boolean | undefined;
initializeIfNotPresent?: boolean | undefined;
}>;
export declare const GitSetWorkingDirOutputSchema: z.ZodObject<{
success: z.ZodBoolean;
message: z.ZodString;
path: z.ZodString;
initialized: z.ZodBoolean;
}, "strip", z.ZodTypeAny, {
path: string;
message: string;
success: boolean;
initialized: boolean;
}, {
path: string;
message: string;
success: boolean;
initialized: boolean;
}>;
export type GitSetWorkingDirInput = z.infer<typeof GitSetWorkingDirInputSchema>;
export type GitSetWorkingDirOutput = z.infer<typeof GitSetWorkingDirOutputSchema>;
/**
* 4. IMPLEMENT the core logic function.
* @throws {McpError} If the logic encounters an unrecoverable issue.
*/
export declare function gitSetWorkingDirLogic(params: GitSetWorkingDirInput, context: RequestContext & {
setWorkingDirectory: (path: string) => void;
}): Promise<GitSetWorkingDirOutput>;
//# sourceMappingURL=logic.d.ts.map