aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKonstantin Ryabitsev <konstantin@linuxfoundation.org>2022-07-19 09:11:54 -0400
committerKonstantin Ryabitsev <konstantin@linuxfoundation.org>2022-07-19 09:11:54 -0400
commit54fef1025358a087012142580436b2a494ca8665 (patch)
treefa4a9a9508824b6c8c1b68faf3d8f8dcb146c400
parent41cded9122f22dcc4fe0b6c1bb8e4447dc3b31cd (diff)
downloadb4-54fef1025358a087012142580436b2a494ca8665.tar.gz
submit: reverse order returned by rev-list
git-rev-list returns patches in reverse chronological order by default, which is the opposite of what we need. Add a --reverse to the call to get the expected behaviour. Reported-by: Mattijs Korpershoek <mkorpershoek@baylibre.com> Link: https://lore.kernel.org/tools/87ilnti947.fsf@baylibre.com/ Signed-off-by: Konstantin Ryabitsev <konstantin@linuxfoundation.org>
-rw-r--r--b4/__init__.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/b4/__init__.py b/b4/__init__.py
index 6af2acd..b3aa84f 100644
--- a/b4/__init__.py
+++ b/b4/__init__.py
@@ -2427,7 +2427,7 @@ def git_range_to_patches(gitdir: Optional[str], start: str, end: str,
extrahdrs: Optional[List[Tuple[str, str]]] = None,
keepdate: bool = False) -> List[Tuple[str, email.message.Message]]:
patches = list()
- commits = git_get_command_lines(gitdir, ['rev-list', f'{start}..{end}'])
+ commits = git_get_command_lines(gitdir, ['rev-list', '--reverse', f'{start}..{end}'])
if not commits:
raise RuntimeError(f'Could not run rev-list {start}..{end}')
for commit in commits: