зеркало из https://github.com/microsoft/git.git
Show usage string for 'git stripspace -h'
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Родитель
1507301204
Коммит
4751f11224
|
@ -73,9 +73,11 @@ int cmd_stripspace(int argc, const char **argv, const char *prefix)
|
||||||
struct strbuf buf = STRBUF_INIT;
|
struct strbuf buf = STRBUF_INIT;
|
||||||
int strip_comments = 0;
|
int strip_comments = 0;
|
||||||
|
|
||||||
if (argc > 1 && (!strcmp(argv[1], "-s") ||
|
if (argc == 2 && (!strcmp(argv[1], "-s") ||
|
||||||
!strcmp(argv[1], "--strip-comments")))
|
!strcmp(argv[1], "--strip-comments")))
|
||||||
strip_comments = 1;
|
strip_comments = 1;
|
||||||
|
else if (argc > 1)
|
||||||
|
usage("git stripspace [-s | --strip-comments] < <stream>");
|
||||||
|
|
||||||
if (strbuf_read(&buf, 0, 1024) < 0)
|
if (strbuf_read(&buf, 0, 1024) < 0)
|
||||||
die_errno("could not read the input");
|
die_errno("could not read the input");
|
||||||
|
|
Загрузка…
Ссылка в новой задаче