(
target: Path,
*args: str,
git_dir: Path | None = None,
work_tree: Path | None = None,
)
| 18 | |
| 19 | |
| 20 | def git_output( |
| 21 | target: Path, |
| 22 | *args: str, |
| 23 | git_dir: Path | None = None, |
| 24 | work_tree: Path | None = None, |
| 25 | ) -> str | None: |
| 26 | completed = git_command(target, *args, text=True, git_dir=git_dir, work_tree=work_tree) |
| 27 | output = completed.stdout.strip() |
| 28 | return output if completed.returncode == 0 and output else None |
| 29 | |
| 30 | |
| 31 | def git_bytes( |
no test coverage detected