1
0
Fork 0
mirror of https://github.com/git/git.git synced 2024-05-07 06:56:08 +02:00

submodules: add RECURSE_SUBMODULES_ONLY value

Add the `RECURSE_SUBMODULES_ONLY` enum value to submodule.h.  This enum
value will be used in a later patch to push to indicate that only
submodules should be pushed, while the superproject should remain
unpushed.

Signed-off-by: Brandon Williams <bmwill@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Brandon Williams 2016-12-19 10:25:32 -08:00 committed by Junio C Hamano
parent 14c01bdbe8
commit 6c656c3fe4
2 changed files with 3 additions and 0 deletions

View File

@ -251,6 +251,8 @@ static int parse_push_recurse(const char *opt, const char *arg,
return RECURSE_SUBMODULES_ON_DEMAND;
else if (!strcmp(arg, "check"))
return RECURSE_SUBMODULES_CHECK;
else if (!strcmp(arg, "only"))
return RECURSE_SUBMODULES_ONLY;
else if (die_on_error)
die("bad %s argument: %s", opt, arg);
else

View File

@ -6,6 +6,7 @@ struct argv_array;
struct sha1_array;
enum {
RECURSE_SUBMODULES_ONLY = -5,
RECURSE_SUBMODULES_CHECK = -4,
RECURSE_SUBMODULES_ERROR = -3,
RECURSE_SUBMODULES_NONE = -2,