fetch-pack: support shallow requests

Enable shallow clones and deepen requests using protocol version 2 if
the server 'fetch' command supports the 'shallow' feature.

Signed-off-by: Brandon Williams <bmwill@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Brandon Williams
2018-03-15 10:31:29 -07:00
committed by Junio C Hamano
parent 685fbd3291
commit f7e2050105
4 changed files with 105 additions and 8 deletions

View File

@ -17,5 +17,7 @@ struct packet_reader;
extern enum protocol_version discover_version(struct packet_reader *reader);
extern int server_supports_v2(const char *c, int die_on_error);
extern int server_supports_feature(const char *c, const char *feature,
int die_on_error);
#endif