git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH] gitweb: shortlog now also obeys $hash_parent

From
Giuseppe Bilotta <giuseppe.bilotta@gmail.com>
Date
Aug 8, 2008, 14:12 UTC
Message-ID
<1218204731-9931-1-git-send-email-giuseppe.bilotta@gmail.com>

If $hash_parent is defined, shortlog now limits the list of commits at those between $hash_parent (exclusive) and $hash (inclusive).

Signed-off-by: Giuseppe Bilotta <giuseppe.bilotta@gmail.com>
---
 gitweb/gitweb.perl |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl
index a12ce87..d811dd4 100755
--- a/gitweb/gitweb.perl
+++ b/gitweb/gitweb.perl
@@ -5472,7 +5472,11 @@ sub git_shortlog {
 	}
 	my $refs = git_get_references();
 
-	my @commitlist = parse_commits($hash, 101, (100 * $page));
+	my $commit_hash = $hash;
+	if (defined $hash_parent) {
+		$commit_hash = "$hash_parent..$hash";
+	}
+	my @commitlist = parse_commits($commit_hash, 101, (100 * $page));
 
 	my $paging_nav = format_paging_nav('shortlog', $hash, $head, $page, $#commitlist >= 100);
 	my $next_link = '';
-- 
1.5.6.3
Next: Petr Baudis
Message 1 of 2 in “gitweb: shortlog now also obeys $hash_parent”
  1. gitweb: shortlog now also obeys $hash_parentGiuseppe Bilotta, Aug 8, 2008
  2. Petr BaudisSep 25, 2008

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.