pytc.log.get_git_commit

pytc.log.get_git_commit(repo_path=None)[source]

Get the current git commit hash.

Parameters:

repo_path (Path | None) – Path to the git repository. Defaults to the pytc package directory.

Returns:

The git commit hash (short form), or ‘unknown’ if not available.

Return type:

str