MCPcopy
hub / github.com/desktop/desktop / setupLocalForkOfRepository

Function setupLocalForkOfRepository

app/test/helpers/repositories.ts:266–273  ·  view source on GitHub ↗
(
  t: TestContext,
  upstream: Repository
)

Source from the content-addressed store, hash-verified

264 * local "upstream" repository.
265 */
266export async function setupLocalForkOfRepository(
267 t: TestContext,
268 upstream: Repository
269): Promise<Repository> {
270 const path = await createTempDirectory(t)
271 await git(['clone', '--local', `${upstream.path}`, path], path, 'clone')
272 return new Repository(path, -1, null, false)
273}
274
275/**
276 * Setup a repository with an uninitialized submodule in a branch

Callers 2

setupFunction · 0.90
branch-test.tsFile · 0.90

Calls 2

createTempDirectoryFunction · 0.90
gitFunction · 0.90

Tested by

no test coverage detected