Revert "git-diff: Introduce --index and deprecate --cached."

This reverts commit 4c81c213a4.

Although --cached and --index are confusing wording, the use of
word --cached for git-diff is consistent with git-apply.  It means
"work with index without looking at the working tree".

We should probably come up with better wording for --cached, if
somebody wants to deprecate it.  But making --index and --cached
synonyms for diff while leaving them mean different things for
apply is no good.
This commit is contained in:
Junio C Hamano
2006-12-13 01:33:43 -08:00
parent 1349f87713
commit f2dd1c9adf
2 changed files with 3 additions and 5 deletions

View File

@ -137,7 +137,7 @@ static int builtin_diff_index(struct rev_info *revs,
int cached = 0;
while (1 < argc) {
const char *arg = argv[1];
if (!strcmp(arg, "--index") || !strcmp(arg, "--cached"))
if (!strcmp(arg, "--cached"))
cached = 1;
else
usage(builtin_diff_usage);