diff options
author | Shawn O. Pearce <spearce@spearce.org> | 2010-02-05 12:57:42 -0800 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2010-02-05 20:57:27 -0800 |
commit | 6d525d389fbef814b11e41f196e6656f2e95f412 (patch) | |
tree | cc5ba47678e3a4177f2b9f80e1675521758e109f /t | |
parent | 38a81b4e82ebf57549f2fa082b329c36dffc0b18 (diff) | |
download | git-6d525d389fbef814b11e41f196e6656f2e95f412.tar.gz git-6d525d389fbef814b11e41f196e6656f2e95f412.tar.xz |
receive-pack: Send hook output over side band #2
If the client requests to enable side-band-64k capability we can
safely send any hook stdout or stderr data down side band #2,
so the client can present it to the user.
If side-band-64k isn't enabled, hooks continue to inherit stderr
from the parent receive-pack process.
When the side band channel is being used the push client will wind up
prefixing all server messages with "remote: ", just like fetch does,
so our test vector has to be updated with the new expected output.
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't')
-rwxr-xr-x | t/t5401-update-hooks.sh | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/t/t5401-update-hooks.sh b/t/t5401-update-hooks.sh index 64f66c94f..c3cf397b0 100755 --- a/t/t5401-update-hooks.sh +++ b/t/t5401-update-hooks.sh @@ -118,19 +118,19 @@ test_expect_success 'send-pack produced no output' ' ' cat <<EOF >expect -STDOUT pre-receive -STDERR pre-receive -STDOUT update refs/heads/master -STDERR update refs/heads/master -STDOUT update refs/heads/tofail -STDERR update refs/heads/tofail -STDOUT post-receive -STDERR post-receive -STDOUT post-update -STDERR post-update +remote: STDOUT pre-receive +remote: STDERR pre-receive +remote: STDOUT update refs/heads/master +remote: STDERR update refs/heads/master +remote: STDOUT update refs/heads/tofail +remote: STDERR update refs/heads/tofail +remote: STDOUT post-receive +remote: STDERR post-receive +remote: STDOUT post-update +remote: STDERR post-update EOF test_expect_success 'send-pack stderr contains hook messages' ' - grep ^STD send.err >actual && + grep ^remote: send.err | sed "s/ *\$//" >actual && test_cmp - actual <expect ' |