Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonathan Nieder <jrnieder@gmail.com>2009-11-09 18:04:55 +0300
committerJunio C Hamano <gitster@pobox.com>2009-11-10 22:06:57 +0300
commit03c5c10263fb0d80151d108a4c61253e1d0a8de6 (patch)
tree4cbad025ef1ec20bd6528fade51816791fcbc38e /show-index.c
parent7006b5beceb296e7e853806622204b2b55649fc5 (diff)
Show usage string for 'git show-index -h'
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'show-index.c')
-rw-r--r--show-index.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/show-index.c b/show-index.c
index 45bb535773..63f9da5323 100644
--- a/show-index.c
+++ b/show-index.c
@@ -1,6 +1,9 @@
#include "cache.h"
#include "pack.h"
+static const char show_index_usage[] =
+"git show-index < <packed archive index>";
+
int main(int argc, char **argv)
{
int i;
@@ -8,6 +11,8 @@ int main(int argc, char **argv)
unsigned int version;
static unsigned int top_index[256];
+ if (argc != 1)
+ usage(show_index_usage);
if (fread(top_index, 2 * 4, 1, stdin) != 1)
die("unable to read header");
if (top_index[0] == htonl(PACK_IDX_SIGNATURE)) {