Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions src/gitlogstats/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,9 @@ def main():
"--repository",
help="the public URL of the repository whose logs to parse",
)
group.add_argument(
"-b", "--branch", help="the branch to parse",
)
group.add_argument(
"-rf",
"--repofile",
Expand Down Expand Up @@ -136,6 +139,11 @@ def main():
["git", "pull"], capture_output=True, check=True
) # clone the code from github

if args.branch:
subprocess.run(
["git", "checkout", args.branch], capture_output=True, check=True
) # clone the code from github

git_logs_parser = GitLogsParser(
repo=repo_dir,
start=args.start,
Expand Down