All of lore.kernel.org
 help / color / mirror / Atom feed
From: Adam Simpkins <simpkins@facebook.com>
To: <git@vger.kernel.org>
Cc: Junio C Hamano <gitster@pobox.com>
Subject: [PATCH] graph API: display uninteresting commits as '^' instead of '*'
Date: Wed, 19 Aug 2009 16:06:46 -0700	[thread overview]
Message-ID: <20090819230646.GS8147@facebook.com> (raw)

Using --graph and --show-all together now displays UNINTERESTING commits
using '^' characters instead of '*'.

Something like the following command will demonstrate the change:

   git log --graph --show-all ^HEAD~2 HEAD

Signed-off-by: Adam Simpkins <simpkins@facebook.com>
---
 graph.c |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/graph.c b/graph.c
index 6746d42..50b68a4 100644
--- a/graph.c
+++ b/graph.c
@@ -775,6 +775,14 @@ static void graph_output_commit_char(struct git_graph *graph, struct strbuf *sb)
 	}
 
 	/*
+	 * For UNINTERESTING commits (displayed with --show-all), print '^'
+	 */
+	if (graph->commit->object.flags & UNINTERESTING) {
+		strbuf_addch(sb, '^');
+		return;
+	}
+
+	/*
 	 * If revs->left_right is set, print '<' for commits that
 	 * come from the left side, and '>' for commits from the right
 	 * side.
-- 
1.6.0.4

                 reply	other threads:[~2009-08-19 23:07 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20090819230646.GS8147@facebook.com \
    --to=simpkins@facebook.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.