* git svn --add-author-from implies --use-log-author
@ 2008-06-20 11:31 Fredrik Skolmli
2008-06-20 13:31 ` Mircea Bardac
0 siblings, 1 reply; 7+ messages in thread
From: Fredrik Skolmli @ 2008-06-20 11:31 UTC (permalink / raw)
To: git
Hi,
when running git svn dcommit --add-author-from on a git-svn repository,
--use-log-author is not implied by itself. This causes the rewritten history
to not show the author in the way most users would expect it to be, "Name
<email@domain.tld>", but instead "<user@uuid>".
Instead of forcing people to write "svn dcommit --add-author-from
--use-log-author", is it a bad move to imply the last argument, making the
history look more user-friendly to start with?
Any thoughts?
--
Regards,
Fredrik Skolmli
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: git svn --add-author-from implies --use-log-author
2008-06-20 11:31 git svn --add-author-from implies --use-log-author Fredrik Skolmli
@ 2008-06-20 13:31 ` Mircea Bardac
2008-06-23 20:12 ` Avery Pennarun
0 siblings, 1 reply; 7+ messages in thread
From: Mircea Bardac @ 2008-06-20 13:31 UTC (permalink / raw)
To: git; +Cc: Fredrik Skolmli
Hi,
Fredrik Skolmli wrote:
> when running git svn dcommit --add-author-from on a git-svn repository,
> --use-log-author is not implied by itself. This causes the rewritten history
> to not show the author in the way most users would expect it to be, "Name
> <email@domain.tld>", but instead "<user@uuid>".
>
> Instead of forcing people to write "svn dcommit --add-author-from
> --use-log-author", is it a bad move to imply the last argument, making the
> history look more user-friendly to start with?
The documentation mentions that these 2 parameters are for init and,
like other parameters, I had the feeling they will affect either the
"init" process or the entire existance of the repository. Now that I
look better, I see that there is no "config" note next to them.
From my point of view, they should be repository config options,
affecting all commits. I can't see a reason for having only sometimes
--add-author-from. If you want to commit information about the authors
in regards to a SVN repository, you'll always want that option to be on.
If you want to have authors properly identified when getting something
out of the SVN repository, you'll always want to have --use-log-author on.
I would also like some option to stop pushing a commit if it doesn't
have any From/Signed-off-by line in it.
Mircea
P.S. I am very curious why using From and not Signed-off-by. I had the
feeling that Signed-off-by is being used to also mark the path of a
patch. Also, is there a centralized list of all the ways a patch can be
"marked"
--
http://mircea.bardac.net
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: git svn --add-author-from implies --use-log-author
2008-06-20 13:31 ` Mircea Bardac
@ 2008-06-23 20:12 ` Avery Pennarun
2008-06-23 21:22 ` Mircea Bardac
2008-06-24 7:37 ` Fredrik Skolmli
0 siblings, 2 replies; 7+ messages in thread
From: Avery Pennarun @ 2008-06-23 20:12 UTC (permalink / raw)
To: Mircea Bardac; +Cc: git, Fredrik Skolmli
On 6/20/08, Mircea Bardac <dev@mircea.bardac.net> wrote:
> > when running git svn dcommit --add-author-from on a git-svn repository,
> > --use-log-author is not implied by itself. This causes the rewritten history
> > to not show the author in the way most users would expect it to be, "Name
> > <email@domain.tld>", but instead "<user@uuid>".
> >
> > Instead of forcing people to write "svn dcommit --add-author-from
> > --use-log-author", is it a bad move to imply the last argument, making the
> > history look more user-friendly to start with?
>
> The documentation mentions that these 2 parameters are for init and, like
> other parameters, I had the feeling they will affect either the "init"
> process or the entire existance of the repository. Now that I look better, I
> see that there is no "config" note next to them.
They are separate options; --add-author-from affects dcommit (but not
fetch or clone), while --use-log-author affects fetch and clone (but
not dcommit). They do different things, and I can imagine wanting one
and not the other, so having one imply the other isn't very safe.
You can set config options for these, however:
git config svn.addAuthorFrom true
git config svn.useLogAuthor true
(I actually use "git config --global" to set these on my system so
they apply to all my git-svn repositories.)
> I would also like some option to stop pushing a commit if it doesn't have
> any From/Signed-off-by line in it.
[...]
> P.S. I am very curious why using From and not Signed-off-by. I had the
> feeling that Signed-off-by is being used to also mark the path of a patch.
> Also, is there a centralized list of all the ways a patch can be "marked"
Signed-off-by is a legal declaration. Please read the documentation
carefully before using it.
From: is automatically added (when you enable the option and there's
no Signed-off-by or From already) and is just informational.
Have fun,
Avery
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: git svn --add-author-from implies --use-log-author
2008-06-23 20:12 ` Avery Pennarun
@ 2008-06-23 21:22 ` Mircea Bardac
2008-06-23 21:31 ` Avery Pennarun
2008-06-24 7:37 ` Fredrik Skolmli
1 sibling, 1 reply; 7+ messages in thread
From: Mircea Bardac @ 2008-06-23 21:22 UTC (permalink / raw)
To: Git Mailing List; +Cc: Avery Pennarun
Avery Pennarun wrote:
> You can set config options for these, however:
>
> git config svn.addAuthorFrom true
> git config svn.useLogAuthor true
>
> (I actually use "git config --global" to set these on my system so
> they apply to all my git-svn repositories.)
Oh great. This is what I actually wanted. Makes a lot more sense to have
them as (global) variables.
My initial thought was that there are (somewhere) some variables being
set for the repository by using --add-author-from and --use-log-author
with "git svn clone ...". I find this quite intuitive (and maybe this
should be default?). I can't see a reason for using these options once
and not using them later, but it might just be me.
>> P.S. I am very curious why using From and not Signed-off-by. I had the
>> feeling that Signed-off-by is being used to also mark the path of a patch.
>> Also, is there a centralized list of all the ways a patch can be "marked"
>
> Signed-off-by is a legal declaration. Please read the documentation
> carefully before using it.
>
> From: is automatically added (when you enable the option and there's
> no Signed-off-by or From already) and is just informational.
I have found that Documentation/SubmittingPatches contains info on how
to use "Signed-off-by:"/"Acked-by:"/a little bit of "From:" but, as far
as I remember, others have been/are used. Are they all gathered
somewhere, as recommendations?
Many thanks.
--
Mircea
http://mircea.bardac.net
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: git svn --add-author-from implies --use-log-author
2008-06-23 21:22 ` Mircea Bardac
@ 2008-06-23 21:31 ` Avery Pennarun
0 siblings, 0 replies; 7+ messages in thread
From: Avery Pennarun @ 2008-06-23 21:31 UTC (permalink / raw)
To: Mircea Bardac; +Cc: Git Mailing List
On 6/23/08, Mircea Bardac <dev@mircea.bardac.net> wrote:
> Avery Pennarun wrote:
>
> > You can set config options for these, however:
> >
> > git config svn.addAuthorFrom true
> > git config svn.useLogAuthor true
> >
> > (I actually use "git config --global" to set these on my system so
> > they apply to all my git-svn repositories.)
>
> Oh great. This is what I actually wanted. Makes a lot more sense to have
> them as (global) variables.
>
> My initial thought was that there are (somewhere) some variables being set
> for the repository by using --add-author-from and --use-log-author with "git
> svn clone ...". I find this quite intuitive (and maybe this should be
> default?). I can't see a reason for using these options once and not using
> them later, but it might just be me.
I agree, it's a good idea to save them to the config at git svn clone time.
When I added --add-author-from I just did it like --use-log-author,
then I had to read the source code to find out how to set them as
config variables :)
I'm sure some patches (at least for the documentation) would be welcomed.
> I have found that Documentation/SubmittingPatches contains info on how to
> use "Signed-off-by:"/"Acked-by:"/a little bit of "From:" but, as far as I
> remember, others have been/are used. Are they all gathered somewhere, as
> recommendations?
I don't know of any definitive reference, but Signed-off-by and
Acked-by seem to be the important ones. From: (as part of the commit
message) seems to be a git-svn extension that I invented. From: (as a
header in the commit message) is interpreted as the committer name by
git-am, I think, but you almost never need that.
Have fun,
Avery
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: git svn --add-author-from implies --use-log-author
2008-06-23 20:12 ` Avery Pennarun
2008-06-23 21:22 ` Mircea Bardac
@ 2008-06-24 7:37 ` Fredrik Skolmli
2008-06-24 16:02 ` [PATCH] git-svn docs: mention svn.addAuthorFrom and svn.useLogAuthor config options Avery Pennarun
1 sibling, 1 reply; 7+ messages in thread
From: Fredrik Skolmli @ 2008-06-24 7:37 UTC (permalink / raw)
To: Avery Pennarun; +Cc: Mircea Bardac, git
On Mon, Jun 23, 2008 at 04:12:37PM -0400, Avery Pennarun wrote:
> They are separate options; --add-author-from affects dcommit (but not
> fetch or clone), while --use-log-author affects fetch and clone (but
> not dcommit). They do different things, and I can imagine wanting one
> and not the other, so having one imply the other isn't very safe.
No, I agree implying it isn't safe. The need for implying --use-log-author
when doing --add-author-from might just be me being to lazy to remember both
flags. :-)
> You can set config options for these, however:
>
> git config svn.addAuthorFrom true
> git config svn.useLogAuthor true
>
> (I actually use "git config --global" to set these on my system so
> they apply to all my git-svn repositories.)
Hm, I did not know about these config options. Are they documented somewhere?
- F
--
Regards,
Fredrik Skolmli
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH] git-svn docs: mention svn.addAuthorFrom and svn.useLogAuthor config options.
2008-06-24 7:37 ` Fredrik Skolmli
@ 2008-06-24 16:02 ` Avery Pennarun
0 siblings, 0 replies; 7+ messages in thread
From: Avery Pennarun @ 2008-06-24 16:02 UTC (permalink / raw)
To: git, gitster; +Cc: Avery Pennarun
At least one person got confused because they thought it was necessary to
provide these on the command line every time.
Signed-off-by: Avery Pennarun <apenwarr@gmail.com>
---
Documentation/git-svn.txt | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/Documentation/git-svn.txt b/Documentation/git-svn.txt
index 97bed54..e8200ce 100644
--- a/Documentation/git-svn.txt
+++ b/Documentation/git-svn.txt
@@ -64,13 +64,16 @@ COMMANDS
--use-log-author;;
When retrieving svn commits into git (as part of fetch, rebase, or
dcommit operations), look for the first From: or Signed-off-by: line
- in the log message and use that as the author string.
+ in the log message and use that as the author string. (To enable
+ this permanently, use git config svn.useLogAuthor)
--add-author-from;;
When committing to svn from git (as part of commit or dcommit
operations), if the existing log message doesn't already have a
From: or Signed-off-by: line, append a From: line based on the
- git commit's author string. If you use this, then --use-log-author
- will retrieve a valid author string for all commits.
+ git commit's author string. If you use this, then if you enable
+ --use-log-author it will retrieve a valid author string for all
+ commits. (To enable this option permanently, use git config
+ svn.addAuthorFrom)
--username=<USER>;;
For transports that SVN handles authentication for (http,
https, and plain svn), specify the username. For other
--
1.5.6.56.g29b0d
^ permalink raw reply related [flat|nested] 7+ messages in thread
end of thread, other threads:[~2008-06-24 16:11 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-06-20 11:31 git svn --add-author-from implies --use-log-author Fredrik Skolmli
2008-06-20 13:31 ` Mircea Bardac
2008-06-23 20:12 ` Avery Pennarun
2008-06-23 21:22 ` Mircea Bardac
2008-06-23 21:31 ` Avery Pennarun
2008-06-24 7:37 ` Fredrik Skolmli
2008-06-24 16:02 ` [PATCH] git-svn docs: mention svn.addAuthorFrom and svn.useLogAuthor config options Avery Pennarun
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).