summaryrefslogtreecommitdiff
path: root/diff-cache.c
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <junkio@cox.net>2005-04-20 19:49:16 -0700
committerLibravatar Linus Torvalds <torvalds@ppc970.osdl.org>2005-04-20 19:49:16 -0700
commitc5bac17ad21c8e79fcca21c366832e75be095322 (patch)
treede6864be255ba016d22ddef52cad71f35b334927 /diff-cache.c
parentDuh, just make git-export.c use the proper syntax, everything is fine. (diff)
downloadtgif-c5bac17ad21c8e79fcca21c366832e75be095322.tar.xz
[PATCH] Usage-string fixes.
Usage string fixes to make maintenance easier (only one instance of a string to update not multiple copies). I've spotted and corrected inconsistent usage text in diff-tree while doing this. Also diff-cache and read-tree usage text have been corrected to match their up-to-date features. Earlier, neither "--cached" form of diff-cache nor "-m single-merge" form of read-tree were described. Signed-off-by: Junio C Hamano <junkio@cox.net> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'diff-cache.c')
-rw-r--r--diff-cache.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/diff-cache.c b/diff-cache.c
index 015fd5fec0..5e1d1a6e6d 100644
--- a/diff-cache.c
+++ b/diff-cache.c
@@ -215,6 +215,8 @@ static int diff_cache(void *tree, unsigned long size, struct cache_entry **ac, i
return 0;
}
+static char *diff_cache_usage = "diff-cache [-r] [-z] [--cached] <tree sha1>";
+
int main(int argc, char **argv)
{
unsigned char tree_sha1[20];
@@ -238,11 +240,11 @@ int main(int argc, char **argv)
cached_only = 1;
continue;
}
- usage("diff-cache [-r] [-z] <tree sha1>");
+ usage(diff_cache_usage);
}
if (argc != 2 || get_sha1_hex(argv[1], tree_sha1))
- usage("diff-cache [-r] [-z] <tree sha1>");
+ usage(diff_cache_usage);
tree = read_tree_with_tree_or_commit_sha1(tree_sha1, &size, 0);
if (!tree)