MCPcopy Create free account
hub / github.com/MoonshotAI/kimi-code / makeGitRepo

Function makeGitRepo

packages/server/test/workspaces.e2e.test.ts:99–102  ·  view source on GitHub ↗

Lay down a minimal git fixture: `.git/HEAD` referring to a branch.

(root: string, branch: string)

Source from the content-addressed store, hash-verified

97
98/** Lay down a minimal git fixture: `.git/HEAD` referring to a branch. */
99function makeGitRepo(root: string, branch: string): void {
100 mkdirSync(join(root, '.git'), { recursive: true });
101 writeFileSync(join(root, '.git', 'HEAD'), `ref: refs/heads/${branch}\n`, 'utf8');
102}
103
104interface RegistryFile {
105 version: number;

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected