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

Re: [PATCH] Mention the fact that 'git annotate' is only for backward compatibility.

From
Petr Baudis <pasky@suse.cz>
Date
Sep 4, 2008, 12:30 UTC
Message-ID
<20080904123046.GX10544@machine.or.cz>
In-Reply-To
<1220529652-24050-1-git-send-email-Matthieu.Moy@imag.fr>
On Thu, Sep 04, 2008 at 02:00:52PM +0200, Matthieu Moy wrote:
Show 20 quoted lines
> 
> Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr>
> ---
>  Documentation/git-annotate.txt |    3 +++
>  1 files changed, 3 insertions(+), 0 deletions(-)
> 
> diff --git a/Documentation/git-annotate.txt b/Documentation/git-annotate.txt
> index 8b6b56a..6e05825 100644
> --- a/Documentation/git-annotate.txt
> +++ b/Documentation/git-annotate.txt
> @@ -14,6 +14,9 @@ DESCRIPTION
>  Annotates each line in the given file with information from the commit
>  which introduced the line. Optionally annotate from a given revision.
>  
> +This command exists for backward compatibility. For regular use, you
> +should use linkgit:git-blame[1] instead.
> +
>  OPTIONS
>  -------
>  include::blame-options.txt[]

Can you please also mark it deprecated in the bash completion and command-list.txt?

Will we still keep it around indefinitely or do we have any phase-out plan? If the latter, we should also start printing warning when executing it.

I'm also curious about
                if (suspect->commit->object.flags & UNINTERESTING) {
                        if (blank_boundary)
                                memset(hex, ' ', length);
                        else if (!cmd_is_annotate) {
                                length--;
                                putchar('^');
                        }
                }

in builtin-blame.c. Junio, you introduced this in e68989a739d - why do you use a separate flag instead of OUTPUT_ANNOTATE_COMPAT? The fact that git annotate == git blame -c does not hold true because of this (admittedly obscure case).

-- 
				Petr "Pasky" Baudis
The next generation of interesting software will be done
on the Macintosh, not the IBM PC.  -- Bill Gates
Previous: Matthieu MoyNext: Matthieu Moy
Message 8 of 17 in “blame vs annotate?”
  1. Jonathan del StrotherSep 3, 2008
  2. Miklos VajnaSep 3, 2008
  3. Petr BaudisSep 3, 2008
  4. Junio C HamanoSep 3, 2008
  5. Matthieu MoySep 4, 2008
  6. Sverre RabbelierSep 4, 2008
  7. Mention the fact that 'git annotate' is only for backward compatibility.Matthieu Moy, Sep 4, 2008
  8. Petr BaudisSep 4, 2008
  9. Mention the fact that 'git annotate' is only for backward compatibility.Matthieu Moy, Sep 4, 2008
  10. Junio C HamanoSep 4, 2008
  11. Junio C HamanoSep 4, 2008
  12. Matthieu MoySep 5, 2008
  13. Junio C HamanoSep 5, 2008
  14. Petr BaudisSep 5, 2008
  15. Matthieu MoySep 5, 2008
  16. Junio C HamanoSep 5, 2008
  17. Jakub NarebskiSep 3, 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.