-
-
Notifications
You must be signed in to change notification settings - Fork 954
-
The command git rev-list
has a lot of options including a very useful one --first-parent
: https://git-scm.com/docs/git-rev-list
Is there a way to pass '--first-parent' as an option to Repo.iter_commits()
?
Beta Was this translation helpful? Give feedback.
All reactions
As the documentation of iter_commts()
suggests keyword arguments can be used to pass additional arguments to the underlying git command. Specifically, repo.iter_commits(first_parent=true)
should do the job.
Passing arguments works in most of the GitPython API, here is more on how parameters are converted to CLI flags.
Replies: 1 comment
-
As the documentation of iter_commts()
suggests keyword arguments can be used to pass additional arguments to the underlying git command. Specifically, repo.iter_commits(first_parent=true)
should do the job.
Passing arguments works in most of the GitPython API, here is more on how parameters are converted to CLI flags.
Beta Was this translation helpful? Give feedback.