MCPcopy
hub / github.com/di-sukharev/opencommit / getGitDir

Function getGitDir

out/cli.cjs:85722–85728  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

85720 const diffableFiles = files.filter((file) => !isFileExcludedFromDiff(file));
85721 const { stdout: diff } = await execa(
85722 "git",
85723 ["diff", "--staged", "--", ...diffableFiles],
85724 { cwd: gitDir }
85725 );
85726 return diff;
85727};
85728var getGitDir = async () => {
85729 const { stdout: gitDir } = await execa("git", [
85730 "rev-parse",
85731 "--show-toplevel"

Callers 6

getOpenCommitIgnoreFunction · 0.70
getCoreHooksPathFunction · 0.70
getStagedFilesFunction · 0.70
getChangedFilesFunction · 0.70
gitAddFunction · 0.70
getDiffFunction · 0.70

Calls 1

execaFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…