2006-10-09 18:32:05 +08:00
|
|
|
/*
|
|
|
|
* "git annotate" builtin alias
|
|
|
|
*
|
|
|
|
* Copyright (C) 2006 Ryan Anderson
|
|
|
|
*/
|
|
|
|
#include "git-compat-util.h"
|
2006-11-11 05:36:44 +08:00
|
|
|
#include "builtin.h"
|
2006-10-09 18:32:05 +08:00
|
|
|
|
|
|
|
int cmd_annotate(int argc, const char **argv, const char *prefix)
|
|
|
|
{
|
|
|
|
const char **nargv;
|
|
|
|
int i;
|
|
|
|
nargv = xmalloc(sizeof(char *) * (argc + 2));
|
|
|
|
|
2007-02-06 17:52:04 +08:00
|
|
|
nargv[0] = "annotate";
|
2006-10-09 18:32:05 +08:00
|
|
|
nargv[1] = "-c";
|
|
|
|
|
|
|
|
for (i = 1; i < argc; i++) {
|
|
|
|
nargv[i+1] = argv[i];
|
|
|
|
}
|
|
|
|
nargv[argc + 1] = NULL;
|
|
|
|
|
2006-11-11 05:36:44 +08:00
|
|
|
return cmd_blame(argc + 1, nargv, prefix);
|
2006-10-09 18:32:05 +08:00
|
|
|
}
|
|
|
|
|