]> Lady’s Gitweb - Gitweb/commitdiff
gitweb: Remove unused git_get_{preceding,following}_references
authorJakub Narebski <redacted>
Sun, 27 Aug 2006 21:44:38 +0000 (23:44 +0200)
committerLady <redacted>
Mon, 6 Apr 2026 04:07:10 +0000 (00:07 -0400)
Remove unused (and with errors in implementation)
git_get_{preceding,following}_references subroutines.

Signed-off-by: Jakub Narebski <redacted>
Signed-off-by: Junio C Hamano <redacted>
gitweb.perl

index f32160a201f5ffa3cdc1e1c6be61ffab6d6d2f54dc04ffb9ea862aa559e571cb..a1a6aff8bd3229913ff6bc6506e268ecce6b9a2ae90cbc74f6c7fe8770a9f1d0 100755 (executable)
@@ -784,57 +784,6 @@ sub git_get_references {
        return \%refs;
 }
 
-sub git_get_following_references {
-       my $hash = shift || return undef;
-       my $type = shift;
-       my $base = shift || $hash_base || "HEAD";
-
-       my $refs = git_get_references($type);
-       open my $fd, "-|", $GIT, "rev-list", $base
-               or return undef;
-       my @commits = map { chomp; $_ } <$fd>;
-       close $fd
-               or return undef;
-
-       my @reflist;
-       my $lastref;
-
-       foreach my $commit (@commits) {
-               foreach my $ref (@{$refs->{$commit}}) {
-                       $lastref = $ref;
-                       push @reflist, $lastref;
-               }
-               if ($commit eq $hash) {
-                       last;
-               }
-       }
-
-       return wantarray ? @reflist : $lastref;
-}
-
-sub git_get_preceding_references {
-       my $hash = shift || return undef;
-       my $type = shift;
-
-       my $refs = git_get_references($type);
-       open my $fd, "-|", $GIT, "rev-list", $hash
-               or return undef;
-       my @commits = map { chomp; $_ } <$fd>;
-       close $fd
-               or return undef;
-
-       my @reflist;
-
-       foreach my $commit (@commits) {
-               foreach my $ref (@{$refs->{$commit}}) {
-                       return $ref unless wantarray;
-                       push @reflist, $ref;
-               }
-       }
-
-       return @reflist;
-}
-
 sub git_get_rev_name_tags {
        my $hash = shift || return undef;
 
This page took 0.026805 seconds and 4 git commands to generate.