({ fs, dir, gitdir = join(dir, '.git'), path })
| 33 | * |
| 34 | */ |
| 35 | export async function getConfig({ fs, dir, gitdir = join(dir, '.git'), path }) { |
| 36 | try { |
| 37 | assertParameter('fs', fs) |
| 38 | assertParameter('gitdir', gitdir) |
| 39 | assertParameter('path', path) |
| 40 | |
| 41 | const fsp = new FileSystem(fs) |
| 42 | const updatedGitdir = await discoverGitdir({ fsp, dotgit: gitdir }) |
| 43 | return await _getConfig({ |
| 44 | fs: fsp, |
| 45 | gitdir: updatedGitdir, |
| 46 | path, |
| 47 | }) |
| 48 | } catch (err) { |
| 49 | err.caller = 'git.getConfig' |
| 50 | throw err |
| 51 | } |
| 52 | } |
no test coverage detected
searching dependent graphs…