From: John Keeping <john@keeping.me.uk>
To: git@vger.kernel.org
Cc: Florian Achleitner <florian.achleitner.2.6.31@gmail.com>,
Sverre Rabbelier <srabbelier@gmail.com>
Subject: Remote helpers and signed tags
Date: Sun, 7 Apr 2013 11:34:18 +0100 [thread overview]
Message-ID: <20130407103418.GT2222@serenity.lan> (raw)
It appears to be impossible to push signed tags using a remote helper
that supports only fast-export. This is reported against gitifyhg[1]
but I think it is actually a Git issue.
[1] https://github.com/buchuki/gitifyhg/issues/59
I can reproduce the error using a trivial remote helper (run this in a
clone of git.git):
-- >8 --
cat >git-remote-export <<EOF &&
#!/bin/sh
alias=$1
url=${2-$1}
while read -r line
do
case "$line" in
capabilities)
echo 'export'
echo 'refspec *:*'
echo
;;
list)
echo
;;
export)
while read -r line
do
echo "$line" >&3
test "$line" = done && break
done 3>"$url"
echo
;;
'')
exit
;;
*)
echo >&2 "unsupported command: $line"
exit 1
;;
esac
done
EOF
chmod +x git-remote-export &&
PATH="$(pwd):$PATH" git push "export::$(pwd)/v1.8.2.export" v1.8.2
-- 8< --
This produces:
fatal: Encountered signed tag 572a535454612a046e7dd7404dcca94d6243c788;
use --signed-tag=<mode> to handle it.
fatal: Error while running fast-export
which is not particularly helpful for a user who doesn't know how the
remote helper is implemented, particularly because adding
--signed-tag=<mode> to the command won't work.
I think there are two problems here:
1) The error message is misleading: "--signed-tag" isn't an option
to git-push and as a user I don't know why Git thought I wanted
to run fast-export.
2) There is no way (that I have found) to change the signed-tag
behaviour of git-fast-export when it is being invoked for a
remote helper.
How do remote helpers using the "push" method handle this? In that case
it seems to be completely up to the helper program to decide what to do.
I wonder if the way forward is to do some combination of:
a) Add a --signed-tags option to git-push, which is either passed to
fast-export or given as a new "option signed-tags" to the
remote-helper when using the push interface (and ignored for the
connect interface).
b) Add a configuration variable to specify how to handle signed tags
when pushing to a remote that uses a remote helper that cannot
handle them; something like "remote.<name>.signedTags".
c) Improve the "Error while running fast-export" message to
something more like "Error pushing with fast-export (using helper
git-remote-foo)".
next reply other threads:[~2013-04-07 10:34 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-07 10:34 John Keeping [this message]
2013-04-07 21:46 ` Remote helpers and signed tags Jonathan Nieder
2013-04-08 0:02 ` Sverre Rabbelier
2013-04-14 10:57 ` [PATCH 0/3] Handle signed tags with 'export' remote helpers John Keeping
2013-04-14 10:57 ` [PATCH 1/3] fast-export: add --signed-tags=warn-strip mode John Keeping
2013-04-16 4:09 ` Sverre Rabbelier
2013-04-16 4:47 ` Junio C Hamano
2013-04-16 4:50 ` Sverre Rabbelier
2013-04-16 8:42 ` John Keeping
2013-04-17 4:48 ` Junio C Hamano
2013-04-17 5:02 ` Sverre Rabbelier
2013-04-16 5:32 ` Jonathan Nieder
2013-04-14 10:57 ` [PATCH 2/3] transport-helper: pass --signed-tags=warn-strip to fast-export John Keeping
2013-04-14 10:57 ` [PATCH 3/3] transport-helper: add 'signed-tags' capability John Keeping
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20130407103418.GT2222@serenity.lan \
--to=john@keeping.me.uk \
--cc=florian.achleitner.2.6.31@gmail.com \
--cc=git@vger.kernel.org \
--cc=srabbelier@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.