Skip to content

nd/shallow-deepen updates

Nguyễn Thái Ngọc Duy git 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest26 patches 13 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/26remote-curl.c: convert fetch_git() to use argv_arrayremote-curl.c+17 -231 reply
2/26transport-helper.c: refactor set_helper_option()transport-helper.c+23 -141 reply
3/26upload-pack: move shallow deepen code out of receive_needs()upload-pack.c+52 -470 replies
4/26upload-pack: move "shallow" sending code out of deepen()upload-pack.c+15 -100 replies
5/26upload-pack: remove unused variable "backup"upload-pack.c+4 -50 replies
6/26upload-pack: move "unshallow" sending code out of deepen()upload-pack.c+26 -130 replies
7/26upload-pack: use skip_prefix() instead of starts_with()upload-pack.c+15 -111 reply
8/26upload-pack: tighten number parsing at "deepen" linesupload-pack.c+2 -20 replies
9/26upload-pack: move rev-list code out of check_non_tip()upload-pack.c+25 -191 reply
10/26fetch-pack: use skip_prefix() instead of starts_with()builtin/fetch-pack.c+6 -60 replies
11/26fetch-pack: use a common function for verbose printingfetch-pack.c+42 -460 replies
12/26fetch-pack.c: mark strings for translatingfetch-pack.c+37 -380 replies
13/26fetch-pack: use a separate flag for fetch in deepening modefetch-pack.c fetch-pack.h+9 -60 replies
14/26shallow.c: implement a generic shallow boundary finder based on rev-listcommit.h shallow.c+80 -01 reply
15/26upload-pack: add deepen-since to cut shallow repos based on timeDocumentation/technical/pack-protocol.txt Documentation/technical/protocol-capabilities.txt upload-pack.c+54 -30 replies
16/26fetch: define shallow boundary with --shallow-sinceDocumentation/fetch-options.txt Documentation/git-fetch-pack.txt Documentation/gitremote-helpers.txt +7 more+67 -90 replies
17/26clone: define shallow clone boundary based on time with --shallow-sinceDocumentation/git-clone.txt builtin/clone.c+16 -30 replies
18/26t5500, t5539: tests for shallow depth since a specific datet/t5500-fetch-pack.sh t/t5539-fetch-http-shallow.sh+50 -01 reply
19/26refs: add expand_ref()refs.c refs.h+8 -10 replies
20/26upload-pack: support define shallow boundary by excluding revisionsDocumentation/technical/pack-protocol.txt Documentation/technical/protocol-capabilities.txt upload-pack.c+32 -30 replies
21/26fetch: define shallow boundary with --shallow-excludeDocumentation/fetch-options.txt Documentation/git-fetch-pack.txt Documentation/gitremote-helpers.txt +8 more+97 -41 reply
22/26clone: define shallow clone boundary with --shallow-excludeDocumentation/git-clone.txt builtin/clone.c+22 -11 reply
23/26t5500, t5539: tests for shallow depth excluding a reft/t5500-fetch-pack.sh t/t5539-fetch-http-shallow.sh+44 -01 reply
24/26upload-pack: split check_unreachable() in two, prep for get_reachable_list()upload-pack.c+26 -152 replies
25/26upload-pack: add get_reachable_list()object.h upload-pack.c+50 -41 reply
26/26fetch, upload-pack: --deepen=N extends shallow boundary by N commitsDocumentation/fetch-options.txt Documentation/git-fetch-pack.txt Documentation/gitremote-helpers.txt +12 more+129 -70 replies

Reviews trailers per patch

None of the 26 patches has a Reviewed-by or Acked-by.

PatchDuy NguyenEric SunshineJunio C Hamano
1/26
2/26
3/26
4/26
5/26
6/26
7/26
8/26
9/26
10/26
11/26
12/26
13/26
14/26
15/26
16/26
17/26
18/26
19/26
20/26
21/26
22/26
23/26
24/26
25/26
26/26Helped-by Helped-by Helped-by

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.

Read the v1 thread

Cover letter [PATCH 00/26] nd/shallow-deepen updates

Compared to 'pu'

14/26 has a fix from Jeff, about incorrectly sharing variable for iteration. Interdiff

shallow.c +3 -2
@@ -188,13 +188,14 @@ struct commit_list *get_shallow_commits_by_rev_list(int ac, const char **av,
 	 */
 	for (p = not_shallow_list; p; p = p->next) {
 		struct commit *c = p->item;
+		struct commit_list *parent;
 
 		if (parse_commit(c))
 			die("unable to parse commit %s",
 			    oid_to_hex(&c->object.oid));
 
-		for (p = c->parents; p; p = p->next)
-			if (!(p->item->object.flags & not_shallow_flag)) {
+		for (parent = c->parents; parent; parent = parent->next)
+			if (!(parent->item->object.flags & not_shallow_flag)) {
 				c->object.flags |= shallow_flag;
 				commit_list_insert(c, &result);
 				break;

21/26 adds "static" (from Ramsay Jones)

builtin/fetch.c +1 -1
@@ -41,7 +41,7 @@ static int max_children = 1;
 static const char *depth;
 static const char *deepen_since;
 static const char *upload_pack;
-struct string_list deepen_not = STRING_LIST_INIT_NODUP;
+static struct string_list deepen_not = STRING_LIST_INIT_NODUP;
 static struct strbuf default_rla = STRBUF_INIT;
 static struct transport *gtransport;
 static struct transport *gsecondary;

And 12/26 is a new one.

[01/26] remote-curl.c: convert fetch_git() to use argv_array
[02/26] transport-helper.c: refactor set_helper_option()
[03/26] upload-pack: move shallow deepen code out of receive_needs() [04/26] upload-pack: move "shallow" sending code out of deepen() [05/26] upload-pack: remove unused variable "backup"
[06/26] upload-pack: move "unshallow" sending code out of deepen() [07/26] upload-pack: use skip_prefix() instead of starts_with() [08/26] upload-pack: tighten number parsing at "deepen" lines
[09/26] upload-pack: move rev-list code out of check_non_tip()
[10/26] fetch-pack: use skip_prefix() instead of starts_with()
[11/26] fetch-pack: use a common function for verbose printing
[12/26] fetch-pack.c: mark strings for translating
[13/26] fetch-pack: use a separate flag for fetch in deepening mode [14/26] shallow.c: implement a generic shallow boundary finder based on rev-list [15/26] upload-pack: add deepen-since to cut shallow repos based on time [16/26] fetch: define shallow boundary with --shallow-since
[17/26] clone: define shallow clone boundary based on time with --shallow-since [18/26] t5500, t5539: tests for shallow depth since a specific date [19/26] refs: add expand_ref()
[20/26] upload-pack: support define shallow boundary by excluding revisions [21/26] fetch: define shallow boundary with --shallow-exclude
[22/26] clone: define shallow clone boundary with --shallow-exclude [23/26] t5500, t5539: tests for shallow depth excluding a ref
[24/26] upload-pack: split check_unreachable() in two, prep for get_reachable_list() [25/26] upload-pack: add get_reachable_list()
[26/26] fetch, upload-pack: --deepen=N extends shallow boundary by N commits

Total 23 files changed, 879 insertions(+), 221 deletions(-)