(git_root: str = '.')
| 84 | |
| 85 | |
| 86 | def get_git_common_dir(git_root: str = '.') -> str: |
| 87 | opt = '--git-common-dir' |
| 88 | _, out, _ = cmd_output('git', 'rev-parse', opt, cwd=git_root) |
| 89 | git_common_dir = out.strip() |
| 90 | if git_common_dir != opt: |
| 91 | return os.path.normpath(os.path.join(git_root, git_common_dir)) |
| 92 | else: # pragma: no cover (git < 2.5) |
| 93 | return get_git_dir(git_root) |
| 94 | |
| 95 | |
| 96 | def is_in_merge_conflict() -> bool: |
nothing calls this directly
no test coverage detected