Pulling signed tags
v3 cover Pulling signed tags
The third iteration of the fourth approach to give more confidence on the authenticity of history, but the third approach of giving GPG signature to individual commits is independently useful and has been rebased on top.
Notable differences from the previous round are:
- The way to handle multi-line header lines in a commit object is officially defined --- the second and subsequent lines begin with a single SP to indent them. The "mergetag" header and "gpgsig" header are now expressed using it;
- commit_tree() figures out what "mergetag" extra headers to generate by inspecting the annotation added to the util field of parent commits as before; it uses a new lower level commit_tree_extended() API to record the extra headers.
- "commit --amend" propagates "mergetag" extra header from the original (but not "gpgsig" for obvious reasons).
. Split GPG interface into its own helper library
. fetch: do not store peeled tag object names in FETCH_HEAD . merge: notice local merging of tags and keep it unwrapped . fetch: allow "git fetch $there v1.0" to fetch a tag
. refs DWIMmery: use the same rule for both "git fetch" and others . fmt-merge-msg: avoid early returns
. fmt-merge-msg: package options into a structure
. fmt-merge-msg: Add contents of merged tag in the merge message . merge: make usage of commit->util more extensible
. merge: record tag objects without peeling in MERGE_HEAD
Unchanged from the previous round.
. commit: copy merged signed tags to headers of merge commit
The way commit_tree() notices that some parents are signed tags and copies them to "mergetag" extra header has been reimplemented by using the new commit_tree_extended() API.
. merge: force edit mode when merging a tag object
Unchanged.
. commit: teach --amend to carry forward extra headers
New. This is the reason commit_tree_extended() was introduced. The plumbing "git commit-tree" should learn to read list of extra headers and record them to its product to help scripts (e.g. "rebase -i"), but it is outside the scope of this series for now.
. commit: teach --gpg-sign option
. log: --show-signature
These two use the new multi-line header format, but otherwise unchanged.
. test "commit -S" and "log --show-signature"
. pretty: %G[?GS] placeholders
Unchanged.
Makefile | 2 + builtin.h | 8 +- builtin/commit-tree.c | 24 ++- builtin/commit.c | 28 ++- builtin/fetch.c | 3 +- builtin/fmt-merge-msg.c | 113 +++++++-- builtin/merge.c | 109 +++++---- builtin/tag.c | 76 +------ builtin/verify-tag.c | 35 +--- cache.h | 2 +- commit.c | 260 +++++++++++++++++++- commit.h | 39 +++- gpg-interface.c | 138 +++++++++++ gpg-interface.h | 10 + log-tree.c | 39 +++ merge-recursive.c | 13 +- notes-cache.c | 2 +- notes-merge.c | 2 +- pretty.c | 86 +++++++ refs.c | 7 - revision.c | 2 + revision.h | 1 + strbuf.c | 14 + strbuf.h | 8 + t/t4202-log.sh | 4 +- t/t5510-fetch.sh | 5 +- t/t5515/fetch.br-branches-default | 6 +- t/t5515/fetch.br-branches-default-merge | 6 +- ...etch.br-branches-default-merge_branches-default | 6 +- t/t5515/fetch.br-branches-default-octopus | 6 +- ...ch.br-branches-default-octopus_branches-default | 6 +- t/t5515/fetch.br-branches-default_branches-default | 6 +- t/t5515/fetch.br-branches-one | 6 +- t/t5515/fetch.br-branches-one-merge | 6 +- t/t5515/fetch.br-branches-one-merge_branches-one | 6 +- t/t5515/fetch.br-branches-one-octopus | 6 +- t/t5515/fetch.br-branches-one-octopus_branches-one | 6 +- t/t5515/fetch.br-branches-one_branches-one | 6 +- t/t5515/fetch.br-config-explicit | 6 +- t/t5515/fetch.br-config-explicit-merge | 6 +- .../fetch.br-config-explicit-merge_config-explicit | 6 +- t/t5515/fetch.br-config-explicit-octopus | 6 +- ...etch.br-config-explicit-octopus_config-explicit | 6 +- t/t5515/fetch.br-config-explicit_config-explicit | 6 +- t/t5515/fetch.br-config-glob | 6 +- t/t5515/fetch.br-config-glob-merge | 6 +- t/t5515/fetch.br-config-glob-merge_config-glob | 6 +- t/t5515/fetch.br-config-glob-octopus | 6 +- t/t5515/fetch.br-config-glob-octopus_config-glob | 6 +- t/t5515/fetch.br-config-glob_config-glob | 6 +- t/t5515/fetch.br-remote-explicit | 6 +- t/t5515/fetch.br-remote-explicit-merge | 6 +- .../fetch.br-remote-explicit-merge_remote-explicit | 6 +- t/t5515/fetch.br-remote-explicit-octopus | 6 +- ...etch.br-remote-explicit-octopus_remote-explicit | 6 +- t/t5515/fetch.br-remote-explicit_remote-explicit | 6 +- t/t5515/fetch.br-remote-glob | 6 +- t/t5515/fetch.br-remote-glob-merge | 6 +- t/t5515/fetch.br-remote-glob-merge_remote-glob | 6 +- t/t5515/fetch.br-remote-glob-octopus | 6 +- t/t5515/fetch.br-remote-glob-octopus_remote-glob | 6 +- t/t5515/fetch.br-remote-glob_remote-glob | 6 +- t/t5515/fetch.br-unconfig | 6 +- t/t5515/fetch.br-unconfig_--tags_.._.git | 6 +- ...nfig_.._.git_one_tag_tag-one_tag_tag-three-file | 6 +- ...fig_.._.git_tag_tag-one-tree_tag_tag-three-file | 6 +- ...h.br-unconfig_.._.git_tag_tag-one_tag_tag-three | 6 +- t/t5515/fetch.br-unconfig_branches-default | 6 +- t/t5515/fetch.br-unconfig_branches-one | 6 +- t/t5515/fetch.br-unconfig_config-explicit | 6 +- t/t5515/fetch.br-unconfig_config-glob | 6 +- t/t5515/fetch.br-unconfig_remote-explicit | 6 +- t/t5515/fetch.br-unconfig_remote-glob | 6 +- t/t5515/fetch.master | 6 +- t/t5515/fetch.master_--tags_.._.git | 6 +- ...ster_.._.git_one_tag_tag-one_tag_tag-three-file | 6 +- ...ter_.._.git_tag_tag-one-tree_tag_tag-three-file | 6 +- .../fetch.master_.._.git_tag_tag-one_tag_tag-three | 6 +- t/t5515/fetch.master_branches-default | 6 +- t/t5515/fetch.master_branches-one | 6 +- t/t5515/fetch.master_config-explicit | 6 +- t/t5515/fetch.master_config-glob | 6 +- t/t5515/fetch.master_remote-explicit | 6 +- t/t5515/fetch.master_remote-glob | 6 +- t/t7510-signed-commit.sh | 71 ++++++ t/t7600-merge.sh | 12 +- t/t7604-merge-custom-message.sh | 2 +- t/t7608-merge-messages.sh | 4 +- tag.c | 5 + 89 files changed, 1080 insertions(+), 392 deletions(-) create mode 100644 gpg-interface.c create mode 100644 gpg-interface.h create mode 100755 t/t7510-signed-commit.sh
Signature · 1 line
1.7.8.rc1.82.g90e080
PATCH v3 1/17 Split GPG interface into its own helper library
This mostly moves existing code from builtin/tag.c (for signing) and builtin/verify-tag.c (for verifying) to a new gpg-interface.c file to provide a more generic library interface.
- sign_buffer() takes a payload strbuf, a signature strbuf, and a signing key, runs "gpg" to produce a detached signature for the payload, and appends it to the signature strbuf. The contents of a signed tag that concatenates the payload and the detached signature can be produced by giving the same strbuf as payload and signature strbuf.
- verify_signed_buffer() takes a payload and a detached signature as <ptr, len> pairs, and runs "gpg --verify" to see if the payload matches the signature. It can optionally capture the output from GPG to allow the callers to pretty-print it in a way more suitable for their contexts.
"verify-tag" (aka "tag -v") used to save the whole tag contents as if it is a detached signature, and fed gpg the payload part of the tag. It relied on gpg to fail when the given tag is not signed but just is annotated. The updated run_gpg_verify() function detects the lack of detached signature in the input, and errors out without bothering "gpg".
--- Makefile | 2 + builtin/tag.c | 76 ++------------------------- builtin/verify-tag.c | 35 ++----------- gpg-interface.c | 138 ++++++++++++++++++++++++++++++++++++++++++++++++++ gpg-interface.h | 10 ++++ tag.c | 5 ++ 6 files changed, 166 insertions(+), 100 deletions(-) create mode 100644 gpg-interface.c create mode 100644 gpg-interface.h
Makefile +2 -0
@@ -528,6 +528,7 @@ LIB_H += exec_cmd.h LIB_H += fsck.h LIB_H += gettext.h LIB_H += git-compat-util.h +LIB_H += gpg-interface.h LIB_H += graph.h LIB_H += grep.h LIB_H += hash.h
@@ -621,6 +622,7 @@ LIB_OBJS += entry.o LIB_OBJS += environment.o LIB_OBJS += exec_cmd.o LIB_OBJS += fsck.o +LIB_OBJS += gpg-interface.o LIB_OBJS += graph.o LIB_OBJS += grep.o LIB_OBJS += hash.o
builtin/tag.c +6 -70
108 lines not on this page · raw message
builtin/verify-tag.c +5 -30
@@ -11,6 +11,7 @@#include "run-command.h" #include <signal.h> #include "parse-options.h" +#include "gpg-interface.h" static const char *const verify_tag_usage[] = {"git verify-tag [-v|--verbose] <tag>..." ,
@@ -19,42 +20,16 @@ static const char * const verify_tag_usage[] = {static int run_gpg_verify (const char *buf,unsigned long size,int verbose) { -struct child_process gpg; -const char *args_gpg[] = {"gpg" ,"--verify" ,"FILE" ,"-" ,NULL }; -char path[PATH_MAX ]; -size_t len; -int fd, ret; +int len; - fd =git_mkstemp (path,PATH_MAX ,".git_vtag_tmpXXXXXX" ); -if (fd <0 ) -return error ("could not create temporary file '%s': %s" , - path,strerror (errno)); -if (write_in_full (fd, buf, size) <0 ) -return error ("failed writing temporary file '%s': %s" , - path,strerror (errno)); -close (fd); - -/* find the length without signature */ len =parse_signature (buf, size);if (verbose)write_in_full (1 , buf, len); -memset (&gpg,0 ,sizeof (gpg)); - gpg.argv = args_gpg; - gpg.in =-1 ; - args_gpg[2 ] = path; -if (start_command (&gpg)) { -unlink (path); -return error ("could not run gpg." ); - } - -write_in_full (gpg.in, buf, len); -close (gpg.in); - ret =finish_command (&gpg); +if (size == len) +return error ("no signature found" ); -unlink_or_warn (path); - -return ret; +return verify_signed_buffer (buf, len, buf + len, size - len,NULL ); }static int verify_tag (const char *name,int verbose)
gpg-interface.c new file +138 -0
138 lines not on this page · raw message
gpg-interface.h new file +10 -0
@@ -0,0 +1,10 @@ +#ifndef GPG_INTERFACE_H +#define GPG_INTERFACE_H + +extern int sign_buffer (struct strbuf *buffer,struct strbuf *signature,const char *signing_key); +extern int verify_signed_buffer (const char *payload,size_t payload_size,const char *signature,size_t signature_size,struct strbuf *gpg_output); +extern int git_gpg_config (const char *,const char *,void *); +extern void set_signing_key (const char *); +extern const char *get_signing_key (void ); + +#endif
tag.c +5 -0
@@ -139,6 +139,11 @@ int parse_tag(struct tag *item)return ret; } +/* +* Look at a signed tag object, and return the offset where +* the embedded detached signature begins, or the end of the +* data when there is no such signature. +*/ size_t parse_signature (const char *buf,unsigned long size) {char *eol;
Signature · 1 line
1.7.8.rc1.82.g90e080
PATCH v3 2/17 fetch: do not store peeled tag object names in FETCH_HEAD
In reply to Junio C HamanoFrom: Linus Torvalds <[email protected]>
We do not want to record tags as parents of a merge when the user does "git pull $there tag v1.0" to merge tagged commit, but that is not a good enough excuse to peel the tag down to commit when storing in FETCH_HEAD. The caller of underlying "git fetch $there tag v1.0" may have other uses of information contained in v1.0 tag in mind.
[jc: the test adjustment is to update for the new expectation]
--- builtin/fetch.c | 3 +-- t/t5515/fetch.br-branches-default | 6 +++--- t/t5515/fetch.br-branches-default-merge | 6 +++--- ...etch.br-branches-default-merge_branches-default | 6 +++--- t/t5515/fetch.br-branches-default-octopus | 6 +++--- ...ch.br-branches-default-octopus_branches-default | 6 +++--- t/t5515/fetch.br-branches-default_branches-default | 6 +++--- t/t5515/fetch.br-branches-one | 6 +++--- t/t5515/fetch.br-branches-one-merge | 6 +++--- t/t5515/fetch.br-branches-one-merge_branches-one | 6 +++--- t/t5515/fetch.br-branches-one-octopus | 6 +++--- t/t5515/fetch.br-branches-one-octopus_branches-one | 6 +++--- t/t5515/fetch.br-branches-one_branches-one | 6 +++--- t/t5515/fetch.br-config-explicit | 6 +++--- t/t5515/fetch.br-config-explicit-merge | 6 +++--- .../fetch.br-config-explicit-merge_config-explicit | 6 +++--- t/t5515/fetch.br-config-explicit-octopus | 6 +++--- ...etch.br-config-explicit-octopus_config-explicit | 6 +++--- t/t5515/fetch.br-config-explicit_config-explicit | 6 +++--- t/t5515/fetch.br-config-glob | 6 +++--- t/t5515/fetch.br-config-glob-merge | 6 +++--- t/t5515/fetch.br-config-glob-merge_config-glob | 6 +++--- t/t5515/fetch.br-config-glob-octopus | 6 +++--- t/t5515/fetch.br-config-glob-octopus_config-glob | 6 +++--- t/t5515/fetch.br-config-glob_config-glob | 6 +++--- t/t5515/fetch.br-remote-explicit | 6 +++--- t/t5515/fetch.br-remote-explicit-merge | 6 +++--- .../fetch.br-remote-explicit-merge_remote-explicit | 6 +++--- t/t5515/fetch.br-remote-explicit-octopus | 6 +++--- ...etch.br-remote-explicit-octopus_remote-explicit | 6 +++--- t/t5515/fetch.br-remote-explicit_remote-explicit | 6 +++--- t/t5515/fetch.br-remote-glob | 6 +++--- t/t5515/fetch.br-remote-glob-merge | 6 +++--- t/t5515/fetch.br-remote-glob-merge_remote-glob | 6 +++--- t/t5515/fetch.br-remote-glob-octopus | 6 +++--- t/t5515/fetch.br-remote-glob-octopus_remote-glob | 6 +++--- t/t5515/fetch.br-remote-glob_remote-glob | 6 +++--- t/t5515/fetch.br-unconfig | 6 +++--- t/t5515/fetch.br-unconfig_--tags_.._.git | 6 +++--- ...nfig_.._.git_one_tag_tag-one_tag_tag-three-file | 6 +++--- ...fig_.._.git_tag_tag-one-tree_tag_tag-three-file | 6 +++--- ...h.br-unconfig_.._.git_tag_tag-one_tag_tag-three | 6 +++--- t/t5515/fetch.br-unconfig_branches-default | 6 +++--- t/t5515/fetch.br-unconfig_branches-one | 6 +++--- t/t5515/fetch.br-unconfig_config-explicit | 6 +++--- t/t5515/fetch.br-unconfig_config-glob | 6 +++--- t/t5515/fetch.br-unconfig_remote-explicit | 6 +++--- t/t5515/fetch.br-unconfig_remote-glob | 6 +++--- t/t5515/fetch.master | 6 +++--- t/t5515/fetch.master_--tags_.._.git | 6 +++--- ...ster_.._.git_one_tag_tag-one_tag_tag-three-file | 6 +++--- ...ter_.._.git_tag_tag-one-tree_tag_tag-three-file | 6 +++--- .../fetch.master_.._.git_tag_tag-one_tag_tag-three | 6 +++--- t/t5515/fetch.master_branches-default | 6 +++--- t/t5515/fetch.master_branches-one | 6 +++--- t/t5515/fetch.master_config-explicit | 6 +++--- t/t5515/fetch.master_config-glob | 6 +++--- t/t5515/fetch.master_remote-explicit | 6 +++--- t/t5515/fetch.master_remote-glob | 6 +++--- 59 files changed, 175 insertions(+), 176 deletions(-)
builtin/fetch.c +1 -2
@@ -436,8 +436,7 @@ static int store_updated_refs(const char *raw_url, const char *remote_name, } note[note_len] ='\0' ;fprintf (fp,"%s\t%s\t%s" , -sha1_to_hex (commit ? commit->object.sha1 : - rm->old_sha1), +sha1_to_hex (rm->old_sha1), rm->merge ?"" :"not-for-merge" , note);for (i =0 ; i < url_len; ++i)
t/t5515/fetch.br-branches-default +3 -3
@@ -1,8 +1,8 @@ # br-branches-default 754b754407bf032e9a2f9d5a9ad05ca79a6b228f branch 'master' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-branches-default-merge +3 -3
@@ -1,9 +1,9 @@ # br-branches-default-merge 754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge branch 'master' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-branches-default-merge_branches-default +3 -3
@@ -1,9 +1,9 @@ # br-branches-default-merge branches-default 754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge branch 'master' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-branches-default-octopus +3 -3
@@ -2,9 +2,9 @@ 754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge branch 'master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-branches-default-octopus_branches-default +3 -3
@@ -2,9 +2,9 @@ 754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge branch 'master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-branches-default_branches-default +3 -3
@@ -1,8 +1,8 @@ # br-branches-default branches-default 754b754407bf032e9a2f9d5a9ad05ca79a6b228f branch 'master' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-branches-one +3 -3
@@ -1,8 +1,8 @@ # br-branches-one 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-branches-one-merge +3 -3
@@ -1,9 +1,9 @@ # br-branches-one-merge 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-branches-one-merge_branches-one +3 -3
@@ -1,9 +1,9 @@ # br-branches-one-merge branches-one 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-branches-one-octopus +3 -3
@@ -1,9 +1,9 @@ # br-branches-one-octopus 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-branches-one-octopus_branches-one +3 -3
@@ -1,9 +1,9 @@ # br-branches-one-octopus branches-one 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-branches-one_branches-one +3 -3
@@ -1,8 +1,8 @@ # br-branches-one branches-one 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-config-explicit +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-config-explicit-merge +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-config-explicit-merge_config-explicit +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-config-explicit-octopus +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 branch 'two' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-config-explicit-octopus_config-explicit +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 branch 'two' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-config-explicit_config-explicit +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-config-glob +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-config-glob-merge +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-config-glob-merge_config-glob +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-config-glob-octopus +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-config-glob-octopus_config-glob +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-config-glob_config-glob +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-remote-explicit +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-remote-explicit-merge +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-remote-explicit-merge_remote-explicit +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-remote-explicit-octopus +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 branch 'two' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-remote-explicit-octopus_remote-explicit +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 branch 'two' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-remote-explicit_remote-explicit +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-remote-glob +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-remote-glob-merge +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-remote-glob-merge_remote-glob +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-remote-glob-octopus +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-remote-glob-octopus_remote-glob +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-remote-glob_remote-glob +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-unconfig +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-unconfig_--tags_.._.git +3 -3
@@ -1,7 +1,7 @@ # br-unconfig --tags ../.git -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-unconfig_.._.git_one_tag_tag-one_tag_tag-three-file +3 -3
@@ -2,7 +2,7 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 tag 'tag-one' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-unconfig_.._.git_tag_tag-one-tree_tag_tag-three-file +3 -3
@@ -1,7 +1,7 @@ # br-unconfig ../.git tag tag-one-tree tag tag-three-file 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-unconfig_.._.git_tag_tag-one_tag_tag-three +3 -3
@@ -1,7 +1,7 @@ # br-unconfig ../.git tag tag-one tag tag-three 8e32a6d901327a23ef831511badce7bf3bf46689 tag 'tag-one' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b tag 'tag-three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 tag 'tag-three' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-unconfig_branches-default +3 -3
@@ -1,8 +1,8 @@ # br-unconfig branches-default 754b754407bf032e9a2f9d5a9ad05ca79a6b228f branch 'master' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-unconfig_branches-one +3 -3
@@ -1,8 +1,8 @@ # br-unconfig branches-one 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-unconfig_config-explicit +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-unconfig_config-glob +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-unconfig_remote-explicit +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.br-unconfig_remote-glob +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.master +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.master_--tags_.._.git +3 -3
@@ -1,7 +1,7 @@ # master --tags ../.git -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.master_.._.git_one_tag_tag-one_tag_tag-three-file +3 -3
@@ -2,7 +2,7 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 tag 'tag-one' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.master_.._.git_tag_tag-one-tree_tag_tag-three-file +3 -3
@@ -1,7 +1,7 @@ # master ../.git tag tag-one-tree tag tag-three-file 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.master_.._.git_tag_tag-one_tag_tag-three +3 -3
@@ -1,7 +1,7 @@ # master ../.git tag tag-one tag tag-three 8e32a6d901327a23ef831511badce7bf3bf46689 tag 'tag-one' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b tag 'tag-three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 tag 'tag-three' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.master_branches-default +3 -3
@@ -1,8 +1,8 @@ # master branches-default 754b754407bf032e9a2f9d5a9ad05ca79a6b228f branch 'master' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.master_branches-one +3 -3
@@ -1,8 +1,8 @@ # master branches-one 8e32a6d901327a23ef831511badce7bf3bf46689 branch 'one' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.master_config-explicit +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.master_config-glob +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.master_remote-explicit +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
t/t5515/fetch.master_remote-glob +3 -3
@@ -3,9 +3,9 @@ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge branch 'one' of ../ 0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge branch 'three' of ../ 6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge branch 'two' of ../ -754b754407bf032e9a2f9d5a9ad05ca79a6b228f not-for-merge tag 'tag-master' of ../ +6c9dec2b923228c9ff994c6cfe4ae16c12408dc5 not-for-merge tag 'tag-master' of ../ 8e32a6d901327a23ef831511badce7bf3bf46689 not-for-merge tag 'tag-one' of ../ 22feea448b023a2d864ef94b013735af34d238ba not-for-merge tag 'tag-one-tree' of ../ -0567da4d5edd2ff4bb292a465ba9e64dcad9536b not-for-merge tag 'tag-three' of ../ +c61a82b60967180544e3c19f819ddbd0c9f89899 not-for-merge tag 'tag-three' of ../ 0e3b14047d3ee365f4f2a1b673db059c3972589c not-for-merge tag 'tag-three-file' of ../ -6134ee8f857693b96ff1cc98d3e2fd62b199e5a8 not-for-merge tag 'tag-two' of ../ +525b7fb068d59950d185a8779dc957c77eed73ba not-for-merge tag 'tag-two' of ../
Signature · 1 line
1.7.8.rc1.82.g90e080
PATCH v3 3/17 merge: notice local merging of tags and keep it unwrapped
In reply to Junio C HamanoThis also updates the autogenerated merge title message from "merge commit X" to "merge tag X", and its effect can be seen in the changes to the test suite.
--- builtin/merge.c | 5 +++++ t/t4202-log.sh | 4 ++-- t/t7600-merge.sh | 6 +++--- t/t7604-merge-custom-message.sh | 2 +- t/t7608-merge-messages.sh | 4 ++-- 5 files changed, 13 insertions(+), 8 deletions(-)
builtin/merge.c +5 -0
@@ -441,6 +441,11 @@ static void merge_name(const char *remote, struct strbuf *msg) sha1_to_hex(branch_head), remote); goto cleanup; } +if (!prefixcmp (found_ref,"refs/tags/" )) { +strbuf_addf (msg,"%s\t\ttag '%s' of .\n" , +sha1_to_hex (branch_head), remote); + goto cleanup; + }if (!prefixcmp (found_ref,"refs/remotes/" )) {strbuf_addf (msg,"%s\t\tremote-tracking branch '%s' of .\n" ,sha1_to_hex (branch_head), remote);
t/t4202-log.sh +2 -2
@@ -346,11 +346,11 @@ test_expect_success 'set up more tangled history' ' ' cat > expect <<\EOF -* Merge commit 'reach' +* Merge tag 'reach' |\ | \ | \ -*-. \ Merge commit 'octopus-a'; commit 'octopus-b' +*-. \ Merge tags 'octopus-a' and 'octopus-b' |\ \ \ * | | | seventh | | * | octopus-b
t/t7600-merge.sh +3 -3
@@ -38,8 +38,8 @@ printf '%s\n' '1 X' 2 3 4 '5 X' 6 7 8 '9 X' >result.1-5-9 >empty create_merge_msgs () { - echo "Merge commit 'c2'" >msg.1-5 && - echo "Merge commit 'c2'; commit 'c3'" >msg.1-5-9 && + echo "Merge tag 'c2'" >msg.1-5 && + echo "Merge tags 'c2' and 'c3'" >msg.1-5-9 && { echo "Squashed commit of the following:" && echo &&
@@ -57,7 +57,7 @@ create_merge_msgs () { } >squash.1-5-9 && echo >msg.nolog && { - echo "* commit 'c3':" && + echo "* tag 'c3':" && echo " commit 3" && echo } >msg.log
t/t7604-merge-custom-message.sh +1 -1
@@ -11,7 +11,7 @@ create_merge_msgs() { cp exp.subject exp.log && echo >>exp.log "" && - echo >>exp.log "* commit 'c2':" && + echo >>exp.log "* tag 'c2':" && echo >>exp.log " c2" }
t/t7608-merge-messages.sh +2 -2
@@ -35,7 +35,7 @@ test_expect_success 'merge tag' ' git checkout master && test_commit master-3 && git merge tag-1 && - check_oneline "Merge commit Qtag-1Q" + check_oneline "Merge tag Qtag-1Q" ' test_expect_success 'ambiguous tag' '
@@ -44,7 +44,7 @@ test_expect_success 'ambiguous tag' ' git checkout master && test_commit master-4 && git merge ambiguous && - check_oneline "Merge commit QambiguousQ" + check_oneline "Merge tag QambiguousQ" ' test_expect_success 'remote-tracking branch' '
Signature · 1 line
1.7.8.rc1.82.g90e080
PATCH v3 4/17 fetch: allow "git fetch $there v1.0" to fetch a tag
In reply to Junio C HamanoYou can already do so with "git fetch $there tags/v1.0" but if it is not ambiguous there is no reason to force users to type more.
--- refs.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
refs.c +1 -0
@@ -998,6 +998,7 @@ const char *ref_rev_parse_rules[] = {const char *ref_fetch_rules[] = {"%.*s" ,"refs/%.*s" , +"refs/tags/%.*s" ,"refs/heads/%.*s" ,NULL };
Signature · 1 line
1.7.8.rc1.82.g90e080
PATCH v3 5/17 refs DWIMmery: use the same rule for both "git fetch" and others
In reply to Junio C Hamano"git log frotz" can DWIM to "refs/remotes/frotz/HEAD", but in the remote access context, "git fetch frotz" to fetch what the other side happened to have fetched from what it calls 'frotz' (which may not have any relation to what we consider is 'frotz') the last time would not make much sense, so the fetch rules table did not include "refs/remotes/%.*s/HEAD".
When the user really wants to, "git fetch $there remotes/frotz/HEAD" would let her do so anyway, so this is not about safety or security; it merely is about confusion avoidance and discouraging meaningless usage.
Specifically, it is _not_ about ambiguity avoidance. A name that would become ambiguous if we use the same rules table for both fetch and local rev-parse would be ambiguous locally at the remote side.
So for the same reason as we added rule to allow "git fetch $there v1.0" instead of "git fetch $there tags/v1.0" in the previous commit, here is a bit longer rope for the users, which incidentally simplifies our code.
--- cache.h | 2 +- refs.c | 8 -------- t/t5510-fetch.sh | 5 ++--- 3 files changed, 3 insertions(+), 12 deletions(-)
cache.h +1 -1
@@ -873,7 +873,7 @@ extern int get_sha1_mb(const char *str, unsigned char *sha1);extern int refname_match (const char *abbrev_name,const char *full_name,const char **rules);extern const char *ref_rev_parse_rules[]; -extern const char *ref_fetch_rules[]; +#define ref_fetch_rules ref_rev_parse_rulesextern int create_symref (const char *ref,const char *refs_heads_master,const char *logmsg);extern int validate_headref (const char *ref);
refs.c +0 -8
@@ -995,14 +995,6 @@ const char *ref_rev_parse_rules[] = { NULL }; -const char *ref_fetch_rules[] = { -"%.*s" , -"refs/%.*s" , -"refs/tags/%.*s" , -"refs/heads/%.*s" , -NULL -}; -int refname_match (const char *abbrev_name,const char *full_name,const char **rules) {const char **p;
t/t5510-fetch.sh +2 -3
@@ -116,7 +116,7 @@ test_expect_success 'fetch must not resolve short tag name' ' ' -test_expect_success 'fetch must not resolve short remote name' ' +test_expect_success 'fetch can now resolve short remote name' ' cd "$D" && git update-ref refs/remotes/six/HEAD HEAD &&
@@ -125,8 +125,7 @@ test_expect_success 'fetch must not resolve short remote name' ' cd six && git init && - test_must_fail git fetch .. six:six - + git fetch .. six:six ' test_expect_success 'create bundle 1' '
Signature · 1 line
1.7.8.rc1.82.g90e080
PATCH v3 6/17 fmt-merge-msg: avoid early returns
In reply to Junio C HamanoIn various places in the codepath, the program tries to return early assuming there is no more work needed. That is generally untrue when over time new features are added.
--- builtin/fmt-merge-msg.c | 20 ++++++++++---------- 1 files changed, 10 insertions(+), 10 deletions(-)
builtin/fmt-merge-msg.c +10 -10
@@ -26,6 +26,7 @@ static int fmt_merge_msg_config(const char *key, const char *value, void *cb)return 0 ; } +/* merge data per repository where the merged tips came from */ struct src_data {struct string_list branch, tag, r_branch, generic;int head_status;
@@ -71,6 +72,11 @@ static int handle_line(char *line) line[len -1 ] =0 ; line +=42 ; +/* +* At this point, line points at the beginning of comment e.g. +* "branch 'frotz' of git://that/repository.git". +* Find the repository name and point it with src. +*/ src =strstr (line," of " );if (src) { *src =0 ;
@@ -283,10 +289,7 @@ static int do_fmt_merge_msg(int merge_title, struct strbuf *in,die ("Error in line %d: %.*s" , i, len, p); } -if (!srcs.nr) -return 0 ; - -if (merge_title) +if (merge_title && srcs.nr)do_fmt_merge_msg_title (out, current_branch);if (shortlog_len) {
@@ -306,6 +309,8 @@ static int do_fmt_merge_msg(int merge_title, struct strbuf *in,shortlog (origins.items[i].string, origins.items[i].util, head, &rev, shortlog_len, out); } +if (out->len && out->buf[out->len-1 ] !='\n' ) +strbuf_addch (out,'\n' );return 0 ; }
@@ -341,12 +346,7 @@ int cmd_fmt_merge_msg(int argc, const char **argv, const char *prefix) 0);if (argc >0 )usage_with_options (fmt_merge_msg_usage, options); -if (message && !shortlog_len) { -char nl ='\n' ; -write_in_full (STDOUT_FILENO , message,strlen (message)); -write_in_full (STDOUT_FILENO , &nl,1 ); -return 0 ; - } +if (shortlog_len <0 )die ("Negative --log=%d" , shortlog_len);
Signature · 1 line
1.7.8.rc1.82.g90e080
PATCH v3 7/17 fmt-merge-msg: package options into a structure
In reply to Junio C HamanoThis way new features can be added more easily
--- builtin.h | 8 +++++++- builtin/fmt-merge-msg.c | 29 ++++++++++++++--------------- builtin/merge.c | 8 ++++++-- 3 files changed, 27 insertions(+), 18 deletions(-)
builtin.h +7 -1
@@ -14,8 +14,14 @@ extern const char git_usage_string[];extern const char git_more_info_string[];extern void prune_packed_objects (int ); + +struct fmt_merge_msg_opts { +unsigned add_title:1 ; +int shortlog_len; +}; +extern int fmt_merge_msg (struct strbuf *in,struct strbuf *out, -int merge_title,int shortlog_len); +struct fmt_merge_msg_opts *);extern void commit_notes (struct notes_tree *t,const char *msg);struct notes_rewrite_cfg {
builtin/fmt-merge-msg.c +14 -15
@@ -209,7 +209,7 @@ static void shortlog(const char *name, unsigned char *sha1,string_list_clear (&subjects,0 ); } -static void do_fmt_merge_msg_title (struct strbuf *out, +static void fmt_merge_msg_title (struct strbuf *out,const char *current_branch) {int i =0 ;char *sep ="" ;
@@ -262,8 +262,9 @@ static void do_fmt_merge_msg_title(struct strbuf *out,strbuf_addf (out," into %s\n" , current_branch); } -static int do_fmt_merge_msg (int merge_title,struct strbuf *in, -struct strbuf *out,int shortlog_len) { +int fmt_merge_msg (struct strbuf *in,struct strbuf *out, +struct fmt_merge_msg_opts *opts) +{int i =0 , pos =0 ;unsigned char head_sha1[20 ];const char *current_branch;
@@ -289,10 +290,10 @@ static int do_fmt_merge_msg(int merge_title, struct strbuf *in,die ("Error in line %d: %.*s" , i, len, p); } -if (merge_title && srcs.nr) -do_fmt_merge_msg_title (out, current_branch); +if (opts->add_title && srcs.nr) +fmt_merge_msg_title (out, current_branch); -if (shortlog_len) { +if (opts->shortlog_len) {struct commit *head;struct rev_info rev;
@@ -307,18 +308,13 @@ static int do_fmt_merge_msg(int merge_title, struct strbuf *in,for (i =0 ; i < origins.nr; i++)shortlog (origins.items[i].string, origins.items[i].util, - head, &rev, shortlog_len, out); + head, &rev, opts->shortlog_len, out); }if (out->len && out->buf[out->len-1 ] !='\n' )strbuf_addch (out,'\n' );return 0 ; } -int fmt_merge_msg (struct strbuf *in,struct strbuf *out, -int merge_title,int shortlog_len) { -return do_fmt_merge_msg (merge_title, in, out, shortlog_len); -} -int cmd_fmt_merge_msg (int argc,const char **argv,const char *prefix) {const char *inpath =NULL ;
@@ -340,6 +336,7 @@ int cmd_fmt_merge_msg(int argc, const char **argv, const char *prefix)FILE *in = stdin;struct strbuf input =STRBUF_INIT , output =STRBUF_INIT ;int ret; +struct fmt_merge_msg_opts opts;git_config (fmt_merge_msg_config,NULL ); argc = parse_options(argc, argv, prefix, options, fmt_merge_msg_usage,
@@ -361,10 +358,12 @@ int cmd_fmt_merge_msg(int argc, const char **argv, const char *prefix)if (message)strbuf_addstr (&output, message); - ret =fmt_merge_msg (&input, &output, - message ?0 :1 , - shortlog_len); +memset (&opts,0 ,sizeof (opts)); + opts.add_title = !message; + opts.shortlog_len = shortlog_len; + + ret =fmt_merge_msg (&input, &output, &opts);if (ret)return ret;write_in_full (STDOUT_FILENO , output.buf, output.len);
builtin/merge.c +6 -2
@@ -1229,8 +1229,12 @@ int cmd_merge(int argc, const char **argv, const char *prefix)merge_name (argv[i], &merge_names);if (!have_message || shortlog_len) { -fmt_merge_msg (&merge_names, &merge_msg, !have_message, - shortlog_len); +struct fmt_merge_msg_opts opts; +memset (&opts,0 ,sizeof (opts)); + opts.add_title = !have_message; + opts.shortlog_len = shortlog_len; + +fmt_merge_msg (&merge_names, &merge_msg, &opts);if (merge_msg.len)strbuf_setlen (&merge_msg, merge_msg.len -1 ); }
Signature · 1 line
1.7.8.rc1.82.g90e080
PATCH v3 8/17 fmt-merge-msg: Add contents of merged tag in the merge message
In reply to Junio C HamanoWhen a contributor asks the integrator to merge her history, a signed tag can be a good vehicle to communicate the authenticity of the request while conveying other information such as the purpose of the topic.
E.g. a signed tag "for-linus" can be created, and the integrator can run:
$ git pull git://example.com/work.git/ for-linus
This would allow the integrator to run "git verify-tag FETCH_HEAD" to validate the signed tag.
Update fmt-merge-msg so that it pre-fills the merge message template with the body (but not signature) of the tag object to help the integrator write a better merge message, in the same spirit as the existing merge.log summary lines.
The message that comes from GPG signature validation is also included in the merge message template to help the integrator verify it, but they are prefixed with "#" to make them comments.
--- builtin/fmt-merge-msg.c | 72 +++++++++++++++++++++++++++++++++++++++++++++- strbuf.c | 14 +++++++++ strbuf.h | 8 +++++ 3 files changed, 92 insertions(+), 2 deletions(-)
builtin/fmt-merge-msg.c +70 -2
@@ -5,6 +5,7 @@#include "revision.h" #include "tag.h" #include "string-list.h" +#include "gpg-interface.h" static const char *const fmt_merge_msg_usage[] = {"git fmt-merge-msg [-m <message>] [--log[=<n>]|--no-log] [--file <file>]" ,
@@ -262,6 +263,70 @@ static void fmt_merge_msg_title(struct strbuf *out,strbuf_addf (out," into %s\n" , current_branch); } +static void fmt_tag_signature (struct strbuf *tagbuf, +struct strbuf *sig, +const char *buf, +unsigned long len) +{ +const char *tag_body =strstr (buf,"\n\n" ); +if (tag_body) { + tag_body +=2 ; +strbuf_add (tagbuf, tag_body, buf + len - tag_body); + } +strbuf_complete_line (tagbuf); +strbuf_add_lines (tagbuf,"# " , sig->buf, sig->len); +} + +static void fmt_merge_msg_sigs (struct strbuf *out) +{ +int i, tag_number =0 , first_tag =0 ; +struct strbuf tagbuf =STRBUF_INIT ; + +for (i =0 ; i < origins.nr; i++) { +unsigned char *sha1 = origins.items[i].util; +enum object_type type; +unsigned long size, len; +char *buf =read_sha1_file (sha1, &type, &size); +struct strbuf sig =STRBUF_INIT ; + +if (!buf || type !=OBJ_TAG ) + goto next; + len =parse_signature (buf, size); + +if (size == len) + ;/* merely annotated */ +else if (verify_signed_buffer (buf, len, buf + len, size - len, &sig)) { +if (!sig.len) +strbuf_addstr (&sig,"gpg verification failed.\n" ); + } + +if (!tag_number++) { +fmt_tag_signature (&tagbuf, &sig, buf, len); + first_tag = i; + }else { +if (tag_number ==2 ) { +struct strbuf tagline =STRBUF_INIT ; +strbuf_addf (&tagline,"\n# %s\n" , + origins.items[first_tag].string); +strbuf_insert (&tagbuf,0 , tagline.buf, + tagline.len); +strbuf_release (&tagline); + } +strbuf_addf (&tagbuf,"\n# %s\n" , + origins.items[i].string); +fmt_tag_signature (&tagbuf, &sig, buf, len); + } +strbuf_release (&sig); + next: +free (buf); + } +if (tagbuf.len) { +strbuf_addch (out,'\n' ); +strbuf_addbuf (out, &tagbuf); + } +strbuf_release (&tagbuf); +} +int fmt_merge_msg (struct strbuf *in,struct strbuf *out,struct fmt_merge_msg_opts *opts) {
@@ -293,6 +358,9 @@ int fmt_merge_msg(struct strbuf *in, struct strbuf *out,if (opts->add_title && srcs.nr)fmt_merge_msg_title (out, current_branch); +if (origins.nr) +fmt_merge_msg_sigs (out); +if (opts->shortlog_len) {struct commit *head;struct rev_info rev;
@@ -310,8 +378,8 @@ int fmt_merge_msg(struct strbuf *in, struct strbuf *out,shortlog (origins.items[i].string, origins.items[i].util, head, &rev, opts->shortlog_len, out); } -if (out->len && out->buf[out->len-1 ] !='\n' ) -strbuf_addch (out,'\n' ); + +strbuf_complete_line (out);return 0 ; }
strbuf.c +14 -0
@@ -397,3 +397,17 @@ int strbuf_read_file(struct strbuf *sb, const char *path, size_t hint)return len; } + +void strbuf_add_lines (struct strbuf *out,const char *prefix, +const char *buf,size_t size) +{ +while (size) { +const char *next =memchr (buf,'\n' , size); + next = next ? (next +1 ) : (buf + size); +strbuf_addstr (out, prefix); +strbuf_add (out, buf, next - buf); + size -= next - buf; + buf = next; + } +strbuf_complete_line (out); +}
strbuf.h +8 -0
@@ -100,6 +100,14 @@ extern void strbuf_addf(struct strbuf *sb, const char *fmt, ...); __attribute__((format (printf,2 ,0 )))extern void strbuf_vaddf (struct strbuf *sb,const char *fmt,va_list ap); +extern void strbuf_add_lines (struct strbuf *sb,const char *prefix,const char *buf,size_t size); + +static inline void strbuf_complete_line (struct strbuf *sb) +{ +if (sb->len && sb->buf[sb->len -1 ] !='\n' ) +strbuf_addch (sb,'\n' ); +} +extern size_t strbuf_fread (struct strbuf *,size_t ,FILE *);/* XXX: if read fails, any partial read is undone */ extern ssize_t strbuf_read (struct strbuf *,int fd,size_t hint);
Signature · 1 line
1.7.8.rc1.82.g90e080
PATCH v3 9/17 merge: make usage of commit->util more extensible
In reply to Junio C HamanoThe merge-recursive code uses the commit->util field directly to annotate the commit objects given from the command line, i.e. the remote heads to be merged, with a single string to be used to describe it in its trace messages and conflict markers.
Correct this short-signtedness by redefining the field to be a pointer to a structure "struct merge_remote_desc" that later enhancements can add more information. Store the original objects we were told to merge in a field "obj" in this struct, so that we can recover the tag we were told to merge.
--- builtin/merge.c | 63 +++++++++++++++++++--------------------------------- commit.c | 19 ++++++++++++++++ commit.h | 13 +++++++++++ merge-recursive.c | 13 +++++------ 4 files changed, 61 insertions(+), 47 deletions(-)
builtin/merge.c +23 -40
@@ -406,20 +406,10 @@ static void finish(struct commit *head_commit,strbuf_release (&reflog_message); } -static struct object *want_commit (const char *name) -{ -struct object *obj; -unsigned char sha1[20 ]; -if (get_sha1 (name, sha1)) -return NULL ; - obj =parse_object (sha1); -return peel_to_type (name,0 , obj,OBJ_COMMIT ); -} -/* Get the name for the merge commit's message. */ static void merge_name (const char *remote,struct strbuf *msg) { -struct object *remote_head; +struct commit *remote_head;unsigned char branch_head[20 ], buf_sha[20 ];struct strbuf buf =STRBUF_INIT ;struct strbuf bname =STRBUF_INIT ;
@@ -431,7 +421,7 @@ static void merge_name(const char *remote, struct strbuf *msg) remote = bname.buf;memset (branch_head,0 ,sizeof (branch_head)); - remote_head =want_commit (remote); + remote_head =get_merge_parent (remote);if (!remote_head)die (_ ("'%s' does not point to a commit" ), remote);
@@ -487,7 +477,7 @@ static void merge_name(const char *remote, struct strbuf *msg)if (resolve_ref (truname.buf, buf_sha,1 ,NULL )) {strbuf_addf (msg,"%s\t\tbranch '%s'%s of .\n" , -sha1_to_hex (remote_head->sha1), +sha1_to_hex (remote_head->object.sha1), truname.buf +11 , (early ?" (early part)" :"" ));strbuf_release (&truname);
@@ -515,7 +505,7 @@ static void merge_name(const char *remote, struct strbuf *msg) goto cleanup; }strbuf_addf (msg,"%s\t\tcommit '%s'\n" , -sha1_to_hex (remote_head->sha1), remote); +sha1_to_hex (remote_head->object.sha1), remote); cleanup:strbuf_release (&buf);strbuf_release (&bname);
@@ -719,7 +709,7 @@ static int try_merge_strategy(const char *strategy, struct commit_list *common,die (_ ("Unknown option for merge-recursive: -X%s" ), xopts[x]); o.branch1 = head_arg; - o.branch2 = remoteheads->item->util; + o.branch2 =merge_remote_util (remoteheads->item)->name;for (j = common; j; j = j->next)commit_list_insert (j->item, &reversed);
@@ -1190,7 +1180,7 @@ int cmd_merge(int argc, const char **argv, const char *prefix) argv +=2 ; argc -=2 ; }else if (!head_commit) { -struct object *remote_head; +struct commit *remote_head;/* * If the merged head is a valid one there is no reason * to forbid "git merge" into a branch yet to be born.
@@ -1204,12 +1194,12 @@ int cmd_merge(int argc, const char **argv, const char *prefix)if (!allow_fast_forward)die (_ ("Non-fast-forward commit does not make sense into " "an empty head" )); - remote_head =want_commit (argv[0 ]); + remote_head =get_merge_parent (argv[0 ]);if (!remote_head)die (_ ("%s - not something we can merge" ), argv[0 ]); -read_empty (remote_head->sha1,0 ); -update_ref ("initial pull" ,"HEAD" , remote_head->sha1,NULL ,0 , -DIE_ON_ERR ); +read_empty (remote_head->object.sha1,0 ); +update_ref ("initial pull" ,"HEAD" , remote_head->object.sha1, +NULL ,0 ,DIE_ON_ERR );return 0 ; }else {struct strbuf merge_names =STRBUF_INIT ;
@@ -1218,12 +1208,9 @@ int cmd_merge(int argc, const char **argv, const char *prefix) head_arg ="HEAD" ;/* -* All the rest are the commits being merged; -* prepare the standard merge summary message to -* be appended to the given message. If remote -* is invalid we will die later in the common -* codepath so we discard the error in this -* loop. +* All the rest are the commits being merged; prepare +* the standard merge summary message to be appended +* to the given message. */ for (i =0 ; i < argc; i++)merge_name (argv[i], &merge_names);
@@ -1251,17 +1238,12 @@ int cmd_merge(int argc, const char **argv, const char *prefix)strbuf_reset (&buf);for (i =0 ; i < argc; i++) { -struct object *o; -struct commit *commit; - - o =want_commit (argv[i]); -if (!o) +struct commit *commit =get_merge_parent (argv[i]); +if (!commit)die (_ ("%s - not something we can merge" ), argv[i]); - commit =lookup_commit (o->sha1); - commit->util = (void *)argv[i]; remotes = &commit_list_insert (commit, remotes)->next; - -strbuf_addf (&buf,"GITHEAD_%s" ,sha1_to_hex (o->sha1)); +strbuf_addf (&buf,"GITHEAD_%s" , +sha1_to_hex (commit->object.sha1));setenv (buf.buf, argv[i],1 );strbuf_reset (&buf); }
@@ -1307,7 +1289,7 @@ int cmd_merge(int argc, const char **argv, const char *prefix) !hashcmp(common->item->object.sha1, head_commit->object.sha1)) {/* Again the most common case of merging one remote. */ struct strbuf msg =STRBUF_INIT ; -struct object *o; +struct commit *commit;char hex[41 ];strcpy (hex,find_unique_abbrev (head_commit->object.sha1,DEFAULT_ABBREV ));
@@ -1321,14 +1303,15 @@ int cmd_merge(int argc, const char **argv, const char *prefix)if (have_message)strbuf_addstr (&msg," (no commit created; -m option ignored)" ); - o =want_commit (sha1_to_hex (remoteheads->item->object.sha1)); -if (!o) + commit = remoteheads->item; +if (!commit)return 1 ; -if (checkout_fast_forward (head_commit->object.sha1, remoteheads->item->object.sha1)) +if (checkout_fast_forward (head_commit->object.sha1, + commit->object.sha1))return 1 ; -finish (head_commit, o->sha1, msg.buf); +finish (head_commit, commit->object.sha1, msg.buf);drop_save ();return 0 ; }else if (!remoteheads->next && common->next)
commit.c +19 -0
@@ -894,3 +894,22 @@ int commit_tree(const char *msg, unsigned char *tree,strbuf_release (&buffer);return result; } + +struct commit *get_merge_parent (const char *name) +{ +struct object *obj; +struct commit *commit; +unsigned char sha1[20 ]; +if (get_sha1 (name, sha1)) +return NULL ; + obj =parse_object (sha1); + commit = (struct commit *)peel_to_type (name,0 , obj,OBJ_COMMIT ); +if (commit && !commit->util) { +struct merge_remote_desc *desc; + desc =xmalloc (sizeof (*desc)); + desc->obj = obj; + desc->name =strdup (name); + commit->util = desc; + } +return commit; +}
commit.h +13 -0
@@ -185,4 +185,17 @@ extern int commit_tree(const char *msg, unsigned char *tree, struct commit_list *parents, unsigned char *ret, const char *author); +struct merge_remote_desc { +struct object *obj;/* the named object, could be a tag */ +const char *name; +}; +#define merge_remote_util (commit) ((struct merge_remote_desc *)((commit)->util)) + +/* +* Given "name" from the command line to merge, find the commit object +* and return it, while storing merge_remote_desc in its ->util field, +* to allow callers to tell if we are told to merge a tag. +*/ +struct commit *get_merge_parent (const char *name); +#endif /* COMMIT_H */
merge-recursive.c +6 -7
@@ -38,16 +38,15 @@ static struct tree *shift_tree_object(struct tree *one, struct tree *two,return lookup_tree (shifted); } -/* -* A virtual commit has (const char *)commit->util set to the name. -*/ -static struct commit *make_virtual_commit (struct tree *tree,const char *comment) {struct commit *commit =xcalloc (1 ,sizeof (struct commit )); +struct merge_remote_desc *desc =xmalloc (sizeof (*desc)); + + desc->name = comment; + desc->obj = (struct object *)commit; commit->tree = tree; - commit->util = (void *)comment; -/* avoid warnings */ + commit->util = desc; commit->object.parsed =1 ;return commit; }
@@ -184,7 +183,7 @@ static void output_commit_title(struct merge_options *o, struct commit *commit)for (i = o->call_depth; i--;)fputs (" " , stdout);if (commit->util) -printf ("virtual %s\n" , (char *)commit->util); +printf ("virtual %s\n" ,merge_remote_util (commit)->name);else {printf ("%s " ,find_unique_abbrev (commit->object.sha1,DEFAULT_ABBREV ));if (parse_commit (commit) !=0 )
Signature · 1 line
1.7.8.rc1.82.g90e080
PATCH v3 10/17 merge: record tag objects without peeling in MERGE_HEAD
In reply to Junio C HamanoOtherwise, "git commit" wouldn't have a way to tell that we were in the middle of merging an annotated or signed tag, not a plain commit, after "git merge" stops to ask the user to resolve conflicts.
--- builtin/merge.c | 13 ++++++++++--- t/t7600-merge.sh | 6 +++++- 2 files changed, 15 insertions(+), 4 deletions(-)
builtin/merge.c +10 -3
@@ -1045,9 +1045,16 @@ static void write_merge_state(void)struct commit_list *j;struct strbuf buf =STRBUF_INIT ; -for (j = remoteheads; j; j = j->next) -strbuf_addf (&buf,"%s\n" , -sha1_to_hex (j->item->object.sha1)); +for (j = remoteheads; j; j = j->next) { +unsigned const char *sha1; +struct commit *c = j->item; +if (c->util &&merge_remote_util (c)->obj) { + sha1 =merge_remote_util (c)->obj->sha1; + }else { + sha1 = c->object.sha1; + } +strbuf_addf (&buf,"%s\n" ,sha1_to_hex (sha1)); + } fd =open (git_path ("MERGE_HEAD" ),O_WRONLY |O_CREAT ,0666 );if (fd <0 ) die_errno(_("Could not open '%s' for writing"),
t/t7600-merge.sh +5 -1
@@ -96,7 +96,11 @@ verify_parents () { verify_mergeheads () { printf '%s\n' "$@" >mergehead.expected && - test_cmp mergehead.expected .git/MERGE_HEAD + while read sha1 rest + do + git rev-parse $sha1 + done <.git/MERGE_HEAD >mergehead.actual && + test_cmp mergehead.expected mergehead.actual } verify_no_mergehead () {
Signature · 1 line
1.7.8.rc1.82.g90e080
PATCH v3 11/17 commit: copy merged signed tags to headers of merge commit
In reply to Junio C HamanoNow MERGE_HEAD records the tag objects without peeling, we could record the result of manual conflict resolution via "git commit" without losing the tag information. Introduce a new "mergetag" multi-line header field to the commit object, and use it to store the entire contents of each signed tag merged.
A commit header that has a multi-line payload begins with the header tag (e.g. "mergetag" in this case), SP, the first line of payload, LF, and all the remaining lines have a SP inserted at the beginning.
In hindsight, it would have been better to make "merge --continue" as the way to continue from such an interrupted merge, not "commit", but this is a backward compatibility baggage we would need to carry around for now.
--- builtin/commit.c | 10 +++--- commit.c | 95 +++++++++++++++++++++++++++++++++++++++++++++++++++-- commit.h | 21 +++++++++++- 3 files changed, 115 insertions(+), 11 deletions(-)
builtin/commit.c +5 -5
@@ -1425,7 +1425,6 @@ int cmd_commit(int argc, const char **argv, const char *prefix) pptr = &commit_list_insert (c->item, pptr)->next; }else if (whence ==FROM_MERGE ) {struct strbuf m =STRBUF_INIT ; -struct commit *commit;FILE *fp;if (!reflog_msg)
@@ -1436,11 +1435,12 @@ int cmd_commit(int argc, const char **argv, const char *prefix)die_errno (_ ("could not open '%s' for reading" ),git_path ("MERGE_HEAD" ));while (strbuf_getline (&m, fp,'\n' ) !=EOF ) { -unsigned char sha1[20 ]; -if (get_sha1_hex (m.buf, sha1) <0 ) +struct commit *parent; + + parent =get_merge_parent (m.buf); +if (!parent)die (_ ("Corrupt MERGE_HEAD file (%s)" ), m.buf); - commit =lookup_commit_or_die (sha1,"MERGE_HEAD" ); - pptr = &commit_list_insert (commit, pptr)->next; + pptr = &commit_list_insert (parent, pptr)->next; }fclose (fp);strbuf_release (&m);
commit.c +91 -4
119 lines not on this page · raw message
commit.h +19 -2
@@ -181,9 +181,26 @@ static inline int single_parent(struct commit *commit)struct commit_list *reduce_heads (struct commit_list *heads); +struct commit_extra_header { +struct commit_extra_header *next; +char *key; +char *value; +size_t len; +}; + +extern void append_merge_tag_headers (struct commit_list *parents, +struct commit_extra_header ***tail); +extern int commit_tree (const char *msg,unsigned char *tree, -struct commit_list *parents,unsigned char *ret, -const char *author); +struct commit_list *parents,unsigned char *ret, +const char *author); + +extern int commit_tree_extended (const char *msg,unsigned char *tree, +struct commit_list *parents,unsigned char *ret, +const char *author, +struct commit_extra_header *); + +extern void free_commit_extra_headers (struct commit_extra_header *extra);struct merge_remote_desc {struct object *obj;/* the named object, could be a tag */
Signature · 1 line
1.7.8.rc1.82.g90e080
PATCH v3 12/17 merge: force edit mode when merging a tag object
In reply to Junio C HamanoNow that we allow pulling a tag from the remote site to validate the authenticity, we should give the user the final chance to verify and edit the merge message.
--- builtin/merge.c | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-)
builtin/merge.c +4 -0
@@ -1253,6 +1253,10 @@ int cmd_merge(int argc, const char **argv, const char *prefix) sha1_to_hex(commit->object.sha1));setenv (buf.buf, argv[i],1 );strbuf_reset (&buf); +if (merge_remote_util (commit) && +merge_remote_util (commit)->obj && +merge_remote_util (commit)->obj->type ==OBJ_TAG ) + option_edit =1 ; }if (!use_strategies) {
Signature · 1 line
1.7.8.rc1.82.g90e080
PATCH v3 13/17 commit: teach --amend to carry forward extra headers
In reply to Junio C HamanoAfter running "git pull $there for-linus" to merge a signed tag, the integrator may need to amend the resulting merge commit to fix typoes in it. Teach --amend option to read the existing extra headers, and carry them forward.
--- builtin/commit.c | 9 ++++++- commit.c | 60 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ commit.h | 3 ++ 3 files changed, 70 insertions(+), 2 deletions(-)
builtin/commit.c +7 -2
@@ -1382,6 +1382,7 @@ int cmd_commit(int argc, const char **argv, const char *prefix)int allow_fast_forward =1 ;struct wt_status s;struct commit *current_head =NULL ; +struct commit_extra_header *extra =NULL ;if (argc ==2 && !strcmp (argv[1 ],"-h" ))usage_with_options (builtin_commit_usage, builtin_commit_options);
@@ -1483,12 +1484,16 @@ int cmd_commit(int argc, const char **argv, const char *prefix)exit (1 ); } -if (commit_tree (sb.buf, active_cache_tree->sha1, parents, sha1, - author_ident.buf)) { +if (amend) + extra =read_commit_extra_headers (current_head); + +if (commit_tree_extended (sb.buf, active_cache_tree->sha1, parents, sha1, + author_ident.buf, extra)) {rollback_index_files ();die (_ ("failed to write commit object" )); }strbuf_release (&author_ident); +free_commit_extra_headers (extra); ref_lock =lock_any_ref_for_update ("HEAD" , !current_head
commit.c +60 -0
66 lines not on this page · raw message
commit.h +3 -0
@@ -200,6 +200,9 @@ extern int commit_tree_extended(const char *msg, unsigned char *tree,const char *author, struct commit_extra_header *); +extern struct commit_extra_header *read_commit_extra_headers (struct commit *); +extern struct commit_extra_header *read_commit_extra_header_lines (const char *buf,size_t len); +extern void free_commit_extra_headers (struct commit_extra_header *extra);struct merge_remote_desc {
Signature · 1 line
1.7.8.rc1.82.g90e080
PATCH v3 14/17 commit: teach --gpg-sign option
In reply to Junio C HamanoThis uses the gpg-interface.[ch] to allow signing the commit, i.e.
$ git commit --gpg-sign -m foo
You need a passphrase to unlock the secret key for
user: "Junio C Hamano <[email protected]>"
4096-bit RSA key, ID 96AFE6CB, created 2011-10-03 (main key ID 713660A7) [master 8457d13] foo
1 files changed, 1 insertions(+), 0 deletions(-)
The lines of GPG detached signature are placed in a new multi-line header field, instead of tucking the signature block at the end of the commit log message text (similar to how signed tag is done), for multiple reasons:
- The signature won't clutter output from "git log" and friends if it is in the extra header. If we place it at the end of the log message, we would need to teach "git log" and friends to strip the signature block with an option.
- Teaching new versions of "git log" and "gitk" to optionally verify and show signatures is cleaner if we structurally know where the signature block is (instead of scanning in the commit log message).
- The signature needs to be stripped upon various commit rewriting operations, e.g. rebase, filter-branch, etc. They all already ignore unknown headers, but if we place signature in the log message, all of these tools (and third-party tools) also need to learn how a signature block would look like.
- When we added the optional encoding header, all the tools (both in tree and third-party) that acts on the raw commit object should have been fixed to ignore headers they do not understand, so it is not like that new header would be more likely to break than extra text in the commit.
A commit made with the above sample sequence would look like this:
$ git cat-file commit HEAD
tree 3cd71d90e3db4136e5260ab54599791c4f883b9d
parent b87755351a47b09cb27d6913e6e0e17e6254a4d4
author Junio C Hamano <[email protected]> 1317862251 -0700
committer Junio C Hamano <[email protected]> 1317862251 -0700
gpgsig -----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux) iQIcBAABAgAGBQJOjPtrAAoJELC16IaWr+bL4TMP/RSe2Y/jYnCkds9unO5JEnfG
...
=dt98
-----END PGP SIGNATURE-----
foobut "git log" (unless you ask for it with --pretty=raw) output is not cluttered with the signature information.
--- builtin/commit-tree.c | 24 +++++++++++++++++++++--- builtin/commit.c | 11 ++++++++++- builtin/merge.c | 16 ++++++++++++++-- commit.c | 48 +++++++++++++++++++++++++++++++++++++++++++++--- commit.h | 4 ++-- notes-cache.c | 2 +- notes-merge.c | 2 +- 7 files changed, 94 insertions(+), 13 deletions(-)
builtin/commit-tree.c +21 -3
@@ -8,8 +8,9 @@#include "tree.h" #include "builtin.h" #include "utf8.h" +#include "gpg-interface.h" -static const char commit_tree_usage[] ="git commit-tree <sha1> [(-p <sha1>)...] < changelog" ; +static const char commit_tree_usage[] ="git commit-tree [-S<signer>] <sha1> [(-p <sha1>)...] < changelog" ;static void new_parent (struct commit *parent,struct commit_list **parents_p) {
@@ -25,6 +26,14 @@ static void new_parent(struct commit *parent, struct commit_list **parents_p)commit_list_insert (parent, parents_p); } +static int commit_tree_config (const char *var,const char *value,void *cb) +{ +int status =git_gpg_config (var, value,NULL ); +if (status) +return status; +return git_default_config (var, value, cb); +} +int cmd_commit_tree (int argc,const char **argv,const char *prefix) {int i;
@@ -32,11 +41,19 @@ int cmd_commit_tree(int argc, const char **argv, const char *prefix)unsigned char tree_sha1[20 ];unsigned char commit_sha1[20 ];struct strbuf buffer =STRBUF_INIT ; +const char *sign_commit =NULL ; -git_config (git_default_config,NULL ); +git_config (commit_tree_config,NULL );if (argc <2 || !strcmp (argv[1 ],"-h" ))usage (commit_tree_usage); + +if (!memcmp (argv[1 ],"-S" ,2 )) { + sign_commit = argv[1 ] +2 ; + argv++; + argc--; + } +if (get_sha1 (argv[1 ], tree_sha1))die ("Not a valid object name %s" , argv[1 ]);
@@ -56,7 +73,8 @@ int cmd_commit_tree(int argc, const char **argv, const char *prefix)if (strbuf_read (&buffer,0 ,0 ) <0 )die_errno ("git commit-tree: failed to read" ); -if (commit_tree (buffer.buf, tree_sha1, parents, commit_sha1,NULL )) { +if (commit_tree (buffer.buf, tree_sha1, parents, commit_sha1, +NULL , sign_commit)) {strbuf_release (&buffer);return 1 ; }
builtin/commit.c +10 -1
@@ -26,6 +26,7 @@#include "unpack-trees.h" #include "quote.h" #include "submodule.h" +#include "gpg-interface.h" static const char *const builtin_commit_usage[] = {"git commit [options] [--] <filepattern>..." ,
@@ -85,6 +86,8 @@ static int all, edit_flag, also, interactive, patch_interactive, only, amend, sistatic int quiet, verbose, no_verify, allow_empty, dry_run, renew_authorship;static int no_post_rewrite, allow_empty_message;static char *untracked_files_arg, *force_date, *ignore_submodule_arg; +static char *sign_commit; +/* * The default commit message cleanup mode will remove the lines * beginning with # (shell comments) and leading and trailing
@@ -144,6 +147,8 @@ static struct option builtin_commit_options[] = {OPT_BOOLEAN ('e' ,"edit" , &edit_flag,"force edit of commit" ),OPT_STRING (0 ,"cleanup" , &cleanup_arg,"default" ,"how to strip spaces and #comments from message" ),OPT_BOOLEAN (0 ,"status" , &include_status,"include status in commit message template" ), + { OPTION_STRING, 'S', "gpg-sign", &sign_commit, "key id", + "GPG sign commit", PARSE_OPT_OPTARG, NULL, (intptr_t) "" },/* end commit message options */ OPT_GROUP("Commit contents options"),
@@ -1324,6 +1329,7 @@ static void print_summary(const char *prefix, const unsigned char *sha1,static int git_commit_config (const char *k,const char *v,void *cb) {struct wt_status *s = cb; +int status;if (!strcmp (k,"commit.template" ))return git_config_pathname (&template_file, k, v);
@@ -1332,6 +1338,9 @@ static int git_commit_config(const char *k, const char *v, void *cb)return 0 ; } + status =git_gpg_config (k, v,NULL ); +if (status) +return status;return git_status_config (k, v, s); }
@@ -1488,7 +1497,7 @@ int cmd_commit(int argc, const char **argv, const char *prefix) extra =read_commit_extra_headers (current_head);if (commit_tree_extended (sb.buf, active_cache_tree->sha1, parents, sha1, - author_ident.buf, extra)) { + author_ident.buf, sign_commit, extra)) {rollback_index_files ();die (_ ("failed to write commit object" )); }
builtin/merge.c +14 -2
@@ -26,6 +26,7 @@#include "merge-recursive.h" #include "resolve-undo.h" #include "remote.h" +#include "gpg-interface.h" #define DEFAULT_TWOHEAD (1<<0)#define DEFAULT_OCTOPUS (1<<1)
@@ -62,6 +63,7 @@ static int allow_rerere_auto;static int abort_current_merge;static int show_progress =-1 ;static int default_to_upstream; +static const char *sign_commit;static struct strategy all_strategy[] = { {"recursive" ,DEFAULT_TWOHEAD |NO_TRIVIAL },
@@ -207,6 +209,8 @@ static struct option builtin_merge_options[] = {OPT_BOOLEAN (0 ,"abort" , &abort_current_merge,"abort the current in-progress merge" ),OPT_SET_INT (0 ,"progress" , &show_progress,"force progress reporting" ,1 ), + { OPTION_STRING, 'S', "gpg-sign", &sign_commit, "key id", + "GPG sign commit", PARSE_OPT_OPTARG, NULL, (intptr_t) "" },OPT_END () };
@@ -533,6 +537,8 @@ static void parse_branch_merge_options(char *bmo)static int git_merge_config (const char *k,const char *v,void *cb) { +int status; +if (branch && !prefixcmp (k,"branch." ) && !prefixcmp (k +7 , branch) && !strcmp (k +7 +strlen (branch),".mergeoptions" )) {
@@ -570,6 +576,10 @@ static int git_merge_config(const char *k, const char *v, void *cb) default_to_upstream =git_config_bool (k, v);return 0 ; } + + status =git_gpg_config (k, v,NULL ); +if (status) +return status;return git_diff_ui_config (k, v, cb); }
@@ -902,7 +912,8 @@ static int merge_trivial(struct commit *head) parent->next->item = remoteheads->item; parent->next->next =NULL ;prepare_to_commit (); -commit_tree (merge_msg.buf, result_tree, parent, result_commit,NULL ); +commit_tree (merge_msg.buf, result_tree, parent, result_commit,NULL , + sign_commit);finish (head, result_commit,"In-index merge" );drop_save ();return 0 ;
@@ -933,7 +944,8 @@ static int finish_automerge(struct commit *head,strbuf_addch (&merge_msg,'\n' );prepare_to_commit ();free_commit_list (remoteheads); -commit_tree (merge_msg.buf, result_tree, parents, result_commit,NULL ); +commit_tree (merge_msg.buf, result_tree, parents, result_commit, +NULL , sign_commit);strbuf_addf (&buf,"Merge made by the '%s' strategy." , wt_strategy);finish (head, result_commit, buf.buf);strbuf_release (&buf);
commit.c +45 -3
83 lines not on this page · raw message
commit.h +2 -2
@@ -193,11 +193,11 @@ extern void append_merge_tag_headers(struct commit_list *parents,extern int commit_tree (const char *msg,unsigned char *tree,struct commit_list *parents,unsigned char *ret, -const char *author); +const char *author,const char *sign_commit);extern int commit_tree_extended (const char *msg,unsigned char *tree,struct commit_list *parents,unsigned char *ret, -const char *author, +const char *author,const char *sign_commit,struct commit_extra_header *);extern struct commit_extra_header *read_commit_extra_headers (struct commit *);
notes-cache.c +1 -1
@@ -56,7 +56,7 @@ int notes_cache_write(struct notes_cache *c)if (write_notes_tree (&c->tree, tree_sha1))return -1 ; -if (commit_tree (c->validity, tree_sha1,NULL , commit_sha1,NULL ) <0 ) +if (commit_tree (c->validity, tree_sha1,NULL , commit_sha1,NULL ,NULL ) <0 )return -1 ;if (update_ref ("update notes cache" , c->tree.ref, commit_sha1,NULL ,0 ,QUIET_ON_ERR ) <0 )
notes-merge.c +1 -1
@@ -546,7 +546,7 @@ void create_notes_commit(struct notes_tree *t, struct commit_list *parents,/* else: t->ref points to nothing, assume root/orphan commit */ } -if (commit_tree (msg, tree_sha1, parents, result_sha1,NULL )) +if (commit_tree (msg, tree_sha1, parents, result_sha1,NULL ,NULL ))die ("Failed to commit notes tree to database" ); }
Signature · 1 line
1.7.8.rc1.82.g90e080
PATCH v3 15/17 log: --show-signature
In reply to Junio C HamanoThis teaches the "log" family of commands to pass the GPG signature in the commit objects to "gpg --verify" via the verify_signed_buffer() interface used to verify signed tag objects. E.g.
$ git show --show-signature -s HEAD
shows GPG output in the header part of the output.
--- commit.c | 44 ++++++++++++++++++++++++++++++++++++++++++++ commit.h | 2 ++ log-tree.c | 39 +++++++++++++++++++++++++++++++++++++++ revision.c | 2 ++ revision.h | 1 + 5 files changed, 88 insertions(+), 0 deletions(-)
commit.c +44 -0
@@ -877,6 +877,50 @@ static int do_sign_commit(struct strbuf *buf, const char *keyid)return 0 ; } +int parse_signed_commit (const unsigned char *sha1, +struct strbuf *payload,struct strbuf *signature) +{ +unsigned long size; +enum object_type type; +char *buffer =read_sha1_file (sha1, &type, &size); +int in_signature, saw_signature =-1 ; +char *line, *tail; + +if (!buffer || type !=OBJ_COMMIT ) + goto cleanup; + + line = buffer; + tail = buffer + size; + in_signature =0 ; + saw_signature =0 ; +while (line < tail) { +const char *sig =NULL ; +char *next =memchr (line,'\n' , tail - line); + + next = next ? next +1 : tail; +if (in_signature && line[0 ] ==' ' ) + sig = line +1 ; +else if (!prefixcmp (line, gpg_sig_header) && + line[gpg_sig_header_len] ==' ' ) + sig = line + gpg_sig_header_len +1 ; +if (sig) { +strbuf_add (signature, sig, next - sig); + saw_signature =1 ; + in_signature =1 ; + }else { +if (*line =='\n' ) +/* dump the whole remainder of the buffer */ + next = tail; +strbuf_add (payload, line, next - line); + in_signature =0 ; + } + line = next; + } + cleanup: +free (buffer); +return saw_signature; +} +static void handle_signed_tag (struct commit *parent,struct commit_extra_header ***tail) {struct merge_remote_desc *desc;
commit.h +2 -0
@@ -218,4 +218,6 @@ struct merge_remote_desc {*/ struct commit *get_merge_parent (const char *name); +extern int parse_signed_commit (const unsigned char *sha1, +struct strbuf *message,struct strbuf *signature);#endif /* COMMIT_H */
log-tree.c +39 -0
@@ -8,6 +8,7 @@#include "refs.h" #include "string-list.h" #include "color.h" +#include "gpg-interface.h" struct decoration name_decoration = {"object names" };
@@ -403,6 +404,41 @@ void log_write_email_headers(struct rev_info *opt, struct commit *commit, *extra_headers_p = extra_headers; } +static void show_signature (struct rev_info *opt,struct commit *commit) +{ +struct strbuf payload =STRBUF_INIT ; +struct strbuf signature =STRBUF_INIT ; +struct strbuf gpg_output =STRBUF_INIT ; +int status; +const char *color, *reset, *bol, *eol; + +if (parse_signed_commit (commit->object.sha1, &payload, &signature) <=0 ) + goto out; + + status =verify_signed_buffer (payload.buf, payload.len, + signature.buf, signature.len, + &gpg_output); +if (status && !gpg_output.len) +strbuf_addstr (&gpg_output,"No signature\n" ); + + color =diff_get_color_opt (&opt->diffopt, + status ?DIFF_WHITESPACE :DIFF_FRAGINFO ); + reset =diff_get_color_opt (&opt->diffopt,DIFF_RESET ); + + bol = gpg_output.buf; +while (*bol) { + eol =strchrnul (bol,'\n' ); +printf ("%s%.*s%s%s" , color, (int )(eol - bol), bol, reset, + *eol ?"\n" :"" ); + bol = (*eol) ? (eol +1 ) : eol; + } + + out: +strbuf_release (&gpg_output); +strbuf_release (&payload); +strbuf_release (&signature); +} +void show_log (struct rev_info *opt) {struct strbuf msgbuf =STRBUF_INIT ;
@@ -514,6 +550,9 @@ void show_log(struct rev_info *opt) } } +if (opt->show_signature) +show_signature (opt, commit); +if (!commit->buffer)return ;
revision.c +2 -0
@@ -1469,6 +1469,8 @@ static int handle_revision_opt(struct rev_info *revs, int argc, const char **arg revs->show_notes =1 ; revs->show_notes_given =1 ; revs->notes_opt.use_default_notes =1 ; + }else if (!strcmp (arg,"--show-signature" )) { + revs->show_signature =1 ; }else if (!prefixcmp (arg,"--show-notes=" ) || !prefixcmp (arg,"--notes=" )) {struct strbuf buf =STRBUF_INIT ;
revision.h +1 -0
@@ -110,6 +110,7 @@ struct rev_info { show_merge:1, show_notes:1, show_notes_given:1, + show_signature:1, pretty_given:1, abbrev_commit:1, abbrev_commit_given:1,
Signature · 1 line
1.7.8.rc1.82.g90e080
PATCH v3 16/17 test "commit -S" and "log --show-signature"
In reply to Junio C Hamano--- t/t7510-signed-commit.sh | 71 ++++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 71 insertions(+), 0 deletions(-) create mode 100755 t/t7510-signed-commit.sh
t/t7510-signed-commit.sh new file +71 -0
@@ -0,0 +1,71 @@ +#!/bin/sh + +test_description='signed commit tests' +. ./test-lib.sh +. "$TEST_DIRECTORY/lib-gpg.sh" + +test_expect_success GPG 'create signed commits' ' + echo 1 >file && git add file && + test_tick && git commit -S -m initial && + git tag initial && + git branch side && + + echo 2 >file && test_tick && git commit -a -S -m second && + git tag second && + + git checkout side && + echo 3 >elif && git add elif && + test_tick && git commit -m "third on side" && + + git checkout master && + test_tick && git merge -S side && + git tag merge && + + echo 4 >file && test_tick && git commit -a -m "fourth unsigned" && + git tag fourth-unsigned && + + test_tick && git commit --amend -S -m "fourth signed" +' + +test_expect_success GPG 'show signatures' ' + ( + for commit in initial second merge master + do + git show --pretty=short --show-signature $commit >actual && + grep "Good signature from" actual || exit 1 + ! grep "BAD signature from" actual || exit 1 + echo $commit OK + done + ) && + ( + for commit in merge^2 fourth-unsigned + do + git show --pretty=short --show-signature $commit >actual && + grep "Good signature from" actual && exit 1 + ! grep "BAD signature from" actual || exit 1 + echo $commit OK + done + ) +' + +test_expect_success GPG 'detect fudged signature' ' + git cat-file commit master >raw && + + sed -e "s/fourth signed/4th forged/" raw >forged1 && + git hash-object -w -t commit forged1 >forged1.commit && + git show --pretty=short --show-signature $(cat forged1.commit) >actual1 && + grep "BAD signature from" actual1 && + ! grep "Good signature from" actual1 +' + +test_expect_success GPG 'detect fudged signature with NUL' ' + git cat-file commit master >raw && + cat raw >forged2 && + echo Qwik | tr "Q" "\000" >>forged2 && + git hash-object -w -t commit forged2 >forged2.commit && + git show --pretty=short --show-signature $(cat forged2.commit) >actual2 && + grep "BAD signature from" actual2 && + ! grep "Good signature from" actual2 +' + +test_done
Signature · 1 line
1.7.8.rc1.82.g90e080
PATCH v3 17/17 pretty: %G[?GS] placeholders
In reply to Junio C HamanoAdd new placeholders related to the GPG signature on signed commits.
- %GG to show the raw verification message from GPG;
- %G? to show either "G" for Good, "B" for Bad;
- %GS to show the name of the signer.
--- pretty.c | 86 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 86 insertions(+), 0 deletions(-)
pretty.c +86 -0
@@ -9,6 +9,7 @@#include "notes.h" #include "color.h" #include "reflog-walk.h" +#include "gpg-interface.h" static char *user_format; static struct cmt_fmt_map {
@@ -640,6 +641,12 @@ struct format_commit_context {const struct pretty_print_context *pretty_ctx; unsigned commit_header_parsed:1; unsigned commit_message_parsed:1; + unsigned commit_signature_parsed:1; +struct { +char *gpg_output; +char good_bad; +char *signer; + } signature;char *message;size_t width, indent1, indent2;
@@ -822,6 +829,59 @@ static void rewrap_message_tail(struct strbuf *sb, c->indent2 = new_indent2; } +static struct { +char result; +const char *check; +} signature_check[] = { + {'G' ,": Good signature from " }, + {'B' ,": BAD signature from " }, +}; + +static void parse_signature_lines (struct format_commit_context *ctx) +{ +const char *buf = ctx->signature.gpg_output; +int i; + +for (i =0 ; i <ARRAY_SIZE (signature_check); i++) { +const char *found =strstr (buf, signature_check[i].check); +const char *next; +if (!found) +continue ; + ctx->signature.good_bad = signature_check[i].result; + found +=strlen (signature_check[i].check); + next =strchrnul (found,'\n' ); + ctx->signature.signer =xmemdupz (found, next - found); +break ; + } +} + +static void parse_commit_signature (struct format_commit_context *ctx) +{ +struct strbuf payload =STRBUF_INIT ; +struct strbuf signature =STRBUF_INIT ; +struct strbuf gpg_output =STRBUF_INIT ; +int status; + + ctx->commit_signature_parsed =1 ; + +if (parse_signed_commit (ctx->commit->object.sha1, + &payload, &signature) <=0 ) + goto out; + status =verify_signed_buffer (payload.buf, payload.len, + signature.buf, signature.len, + &gpg_output); +if (status && !gpg_output.len) + goto out; + ctx->signature.gpg_output =strbuf_detach (&gpg_output,NULL ); +parse_signature_lines (ctx); + + out: +strbuf_release (&gpg_output); +strbuf_release (&payload); +strbuf_release (&signature); +} + +static size_t format_commit_one (struct strbuf *sb,const char *placeholder,void *context) {
@@ -974,6 +1034,30 @@ static size_t format_commit_one(struct strbuf *sb, const char *placeholder,return 0 ; } +if (placeholder[0 ] =='G' ) { +if (!c->commit_signature_parsed) +parse_commit_signature (c); +switch (placeholder[1 ]) { +case 'G' : +if (c->signature.gpg_output) +strbuf_addstr (sb, c->signature.gpg_output); +break ; +case '?' : +switch (c->signature.good_bad) { +case 'G' : +case 'B' : +strbuf_addch (sb, c->signature.good_bad); + } +break ; +case 'S' : +if (c->signature.signer) +strbuf_addstr (sb, c->signature.signer); +break ; + } +return 2 ; + } + +/* For the rest we have to parse the commit header. */ if (!c->commit_header_parsed)parse_commit_header (c);
@@ -1114,6 +1198,8 @@ void format_commit_message(const struct commit *commit,if (context.message != commit->buffer)free (context.message); +free (context.signature.gpg_output); +free (context.signature.signer); } static void pp_header(const struct pretty_print_context *pp,
Signature · 1 line
1.7.8.rc1.82.g90e080
[PATCH 18/17] request-pull: use the annotated tag contents
In reply to Junio C HamanoThe integrator tool will start allowing to pull signed or an annotated tag, i.e.
$ git pull $there tags/for-linus
and the description in the tag is used to convey a meaningful message from the lieutenant to the integrator to justify the history being pulled.
Include the message in the pull request e-mail, as the same information is useful in this context, too. It would encourage the lieutenants to write meaningful messages in their signed tags.
---
* Goes on top of jc/request-pull-show-head-4 that has been cooking in the 'next' branch.
git-request-pull.sh | 14 ++++++++++++++ t/t5150-request-pull.sh | 4 ++++ 2 files changed, 18 insertions(+), 0 deletions(-)
git-request-pull.sh +14 -0
@@ -48,6 +48,8 @@ then fi fi +tag_name=$(git describe --exact "$head^0" 2>/dev/null) + test -n "$base" && test -n "$url" || usage baserev=$(git rev-parse --verify "$base"^0) && headrev=$(git rev-parse --verify "$head"^0) || exit
@@ -82,8 +84,20 @@ then echo "(from the branch description for $branch local branch)" echo git config "branch.$branch_name.description" +fi && + +if test -n "$tag_name" +then + git cat-file tag "$tag_name" | + sed -n -e '1,/^$/d' -e '/^-----BEGIN PGP /q' -e p + echo +fi && + +if test -n "$branch_name" || test -n "$tag_name" +then echo "----------------------------------------------------------------" fi && + git shortlog ^$baserev $headrev && git diff -M --stat --summary $patch $merge_base..$headrev || status=1
t/t5150-request-pull.sh +4 -0
@@ -86,6 +86,7 @@ test_expect_success 'setup: two scripts for reading pull requests' ' s/$downstream_url_for_sed/URL/g s/for-upstream/BRANCH/g s/mnemonic.txt/FILENAME/g + s/^version [0-9]/VERSION/ /^ FILENAME | *[0-9]* [-+]*\$/ b diffstat /^AUTHOR ([0-9]*):\$/ b shortlog p
@@ -201,6 +202,9 @@ test_expect_success 'pull request format' ' SUBJECT (DATE) ---------------------------------------------------------------- + VERSION + + ---------------------------------------------------------------- SHORTLOG DIFFSTAT
Signature · 1 line
1.7.8.rc1.82.gde0f9
Re: [PATCH 19/17] merge: do not fast-forward when merging a tag
Merging a signed or an annotated tag is meant to trigger the editor for the integrator to leave a meaningful merge commit log in the history. Disallow fast-forwarding the merge in such a case to ensure that a merge commit is always recorded.
--- builtin/merge.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-)
builtin/merge.c +3 -1
@@ -1255,8 +1255,10 @@ int cmd_merge(int argc, const char **argv, const char *prefix)strbuf_reset (&buf);if (merge_remote_util (commit) &&merge_remote_util (commit)->obj && -merge_remote_util (commit)->obj->type ==OBJ_TAG ) +merge_remote_util (commit)->obj->type ==OBJ_TAG ) { option_edit =1 ; + allow_fast_forward =0 ; + } }if (!use_strategies) {
Quoted 3 lines · Junio C Hamano
The third iteration of the fourth approach to give more confidence on the authenticity of history, but the third approach of giving GPG signature to individual commits is independently useful and has been rebased on top.
Looks good at initial visual review, I'll give a deep inspection in a day or two (at ApacheCon this week).
Thanks for the perseverance!
Signature · 4 lines
Robin Hugh Johnson Gentoo Linux: Developer, Trustee & Infrastructure Lead E-Mail : [email protected] GnuPG FP : 11AC BA4F 4778 E3F6 E4ED F38E B27B 944E 3488 4E85