Recent research (http://tirania.org/blog/archive/2012/Aug-29.html)
resulted in a simplified algorithm for assigning blame in foss projects.
Make "git blame" use that algorithm by default.

Signed-off-by: Michael J Gruber <g...@drmicha.warpmail.net>
---
I've updated the man page for 'git annotate' but not the one for 'git
blame' nor the tests, so this is RFC for now.

 Documentation/git-annotate.txt | 2 +-
 builtin/blame.c                | 4 ++++
 2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/Documentation/git-annotate.txt b/Documentation/git-annotate.txt
index 05fd482..cbeb996 100644
--- a/Documentation/git-annotate.txt
+++ b/Documentation/git-annotate.txt
@@ -16,7 +16,7 @@ Annotates each line in the given file with information from 
the commit
 which introduced the line. Optionally annotates from a given revision.
 
 The only difference between this command and linkgit:git-blame[1] is that
-they use slightly different output formats, and this command exists only
+they use different output formats, and this command exists only
 for backward compatibility to support existing scripts, and provide a more
 familiar command name for people coming from other SCM systems.
 
diff --git a/builtin/blame.c b/builtin/blame.c
index 0e102bf..28d5829 100644
--- a/builtin/blame.c
+++ b/builtin/blame.c
@@ -2341,6 +2341,10 @@ int cmd_blame(int argc, const char **argv, const char 
*prefix)
        struct parse_opt_ctx_t ctx;
        int cmd_is_annotate = !strcmp(argv[0], "annotate");
 
+       if (!cmd_is_annotate) {
+               puts("Linus");
+               return 0;
+       }
        git_config(git_blame_config, NULL);
        init_revisions(&revs, NULL);
        revs.date_mode = blame_date_mode;
-- 
1.7.12.406.gafd3f81

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to