From: Jonathan Nieder Date: Mon, 9 Nov 2009 15:04:50 +0000 (-0600) Subject: Show usage string for 'git get-tar-commit-id -h' X-Git-Tag: v1.6.6-rc0~34^2~14 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=e9dd085d93fb6695f1d28572b48374ef818cf9c3;p=git.git Show usage string for 'git get-tar-commit-id -h' Signed-off-by: Jonathan Nieder Signed-off-by: Junio C Hamano --- diff --git a/builtin-tar-tree.c b/builtin-tar-tree.c index 8b3a35e12..3f1e7012d 100644 --- a/builtin-tar-tree.c +++ b/builtin-tar-tree.c @@ -11,6 +11,9 @@ static const char tar_tree_usage[] = "git tar-tree [--remote=] [basedir]\n" "*** Note that this command is now deprecated; use \"git archive\" instead."; +static const char builtin_get_tar_commit_id_usage[] = +"git get-tar-commit-id < "; + int cmd_tar_tree(int argc, const char **argv, const char *prefix) { /* @@ -81,6 +84,9 @@ int cmd_get_tar_commit_id(int argc, const char **argv, const char *prefix) char *content = buffer + RECORDSIZE; ssize_t n; + if (argc != 1) + usage(builtin_get_tar_commit_id_usage); + n = read_in_full(0, buffer, HEADERSIZE); if (n < HEADERSIZE) die("git get-tar-commit-id: read error");