( worktreePath: string, timeout: number = GIT_TIMEOUTS.LOCAL )
| 27 | * @returns Configured SimpleGit instance |
| 28 | */ |
| 29 | export function createGit( |
| 30 | worktreePath: string, |
| 31 | timeout: number = GIT_TIMEOUTS.LOCAL |
| 32 | ): SimpleGit { |
| 33 | const options: Partial<SimpleGitOptions> = { |
| 34 | baseDir: worktreePath, |
| 35 | binary: "git", |
| 36 | maxConcurrentProcesses: 6, |
| 37 | timeout: { |
| 38 | block: timeout, |
| 39 | }, |
| 40 | }; |
| 41 | |
| 42 | return simpleGit(options); |
| 43 | } |
| 44 | |
| 45 | /** |
| 46 | * Creates a simple-git instance configured for network operations. |
no outgoing calls
no test coverage detected