pg.ddx.io  pgsql-odbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Git history author/committer fields (was Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions)
5+ messages / 3 participants
[nested] [flat]

* Git history author/committer fields (was Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions)
@ 2014-06-26 07:49 Heikki Linnakangas <hlinnakangas@vmware.com>
  2014-06-26 08:15 ` Re: Git history author/committer fields (was Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions) Craig Ringer <craig@2ndquadrant.com>
  2014-06-26 08:32 ` Re: Git history author/committer fields (was Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions) Craig Ringer <craig@2ndquadrant.com>
  2014-06-27 04:04 ` Re: Git history author/committer fields (was Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions) Inoue, Hiroshi <inoue@tpf.co.jp>
  0 siblings, 3 replies; 5+ messages in thread

From: Heikki Linnakangas @ 2014-06-26 07:49 UTC (permalink / raw)
  To: Inoue, Hiroshi <inoue@tpf.co.jp>; +Cc: Craig Ringer <craig@2ndquadrant.com>; pgsql-odbc

On 06/25/2014 05:26 PM, Craig Ringer wrote:
> Please merge branch fix-syswow64-msdtc from my repo at
> https://github.com/ringerc/psqlODBC.git .

Oh, and while you do that, please avoid creating a merge commit. I hate 
those merge commits when I browse the git history, they're just useless 
noise. Please use "git rebase" to clean up the history in your local 
repository first. You can use "git push --dry-run" before the actual 
push to see what will be done. It will print the commit IDs that it 
would push, something like this:

a87a7dc..de42ed4  master     -> origin/master

You can then do "git log a87a7dc..de42ed4" to see those commits.

Also, it would be good to reset the author/committer information in the 
commit before pushing. Looking at the git history the other day, I was 
quite surprised to see commits from Craig, as I didn't know he's a 
psqlodbc committer. Then I realized that you had merged those commits 
from Craig's github repository :-). You can do "git commit --amend 
--reset" to reset them before pushing, but once you do that, should add 
a line in the commit message itself to give credit for the author of the 
patch.

That's what we do with the PostgreSQL main repository, anyway. We could 
also decide to use the git's Author field to track the original author, 
but at least the Committer field should reflect the actual psqlodbc 
committer. I'm not sure how to change that without changing the Author 
field, though.

- Heikki



-- 
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc



^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: Git history author/committer fields (was Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions)
  2014-06-26 07:49 Git history author/committer fields (was Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions) Heikki Linnakangas <hlinnakangas@vmware.com>
@ 2014-06-26 08:15 ` Craig Ringer <craig@2ndquadrant.com>
  2 siblings, 0 replies; 5+ messages in thread

From: Craig Ringer @ 2014-06-26 08:15 UTC (permalink / raw)
  To: Heikki Linnakangas <hlinnakangas@vmware.com>; Inoue, Hiroshi <inoue@tpf.co.jp>; +Cc: pgsql-odbc

On 06/26/2014 03:49 PM, Heikki Linnakangas wrote:
> On 06/25/2014 05:26 PM, Craig Ringer wrote:
>> Please merge branch fix-syswow64-msdtc from my repo at
>> https://github.com/ringerc/psqlODBC.git .
> 
> Oh, and while you do that, please avoid creating a merge commit. I hate
> those merge commits when I browse the git history, they're just useless
> noise. Please use "git rebase" to clean up the history in your local
> repository first. You can use "git push --dry-run" before the actual
> push to see what will be done. It will print the commit IDs that it
> would push, something like this:
> 
> a87a7dc..de42ed4  master     -> origin/master
> 
> You can then do "git log a87a7dc..de42ed4" to see those commits.

I usually do a rebase to current master before pushing a feature branch
and requesting a merge. I'm surprised a merge commit was created -
someone must've committed other things between when I pushed and when it
was merged. There was a lot happening around then.

The committer may just:

    git merge --ff-only

to reject commits that aren't simply fast-forwards.


Or, as rebase merges are usually trivial, they can:

git checkout theremote/thebranch
git checkout -b thebranch
git rebase master
git checkout master
git merge --ff-only -

which will just rebase on top and merge.

> Also, it would be good to reset the author/committer information in the
> commit before pushing. Looking at the git history the other day, I was
> quite surprised to see commits from Craig, as I didn't know he's a
> psqlodbc committer. 

Heh. Soon I shall have commit to all the drivers, then my evil plans
will finally be put in motion!

> That's what we do with the PostgreSQL main repository, anyway. We could
> also decide to use the git's Author field to track the original author,
> but at least the Committer field should reflect the actual psqlodbc
> committer. I'm not sure how to change that without changing the Author
> field, though.

I had a quick look without seeing anything. The two fields must exist
separately for some reason, though.

-- 
 Craig Ringer                   http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services


-- 
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc



^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: Git history author/committer fields (was Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions)
  2014-06-26 07:49 Git history author/committer fields (was Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions) Heikki Linnakangas <hlinnakangas@vmware.com>
@ 2014-06-26 08:32 ` Craig Ringer <craig@2ndquadrant.com>
  2 siblings, 0 replies; 5+ messages in thread

From: Craig Ringer @ 2014-06-26 08:32 UTC (permalink / raw)
  To: Heikki Linnakangas <hlinnakangas@vmware.com>; Inoue, Hiroshi <inoue@tpf.co.jp>; +Cc: pgsql-odbc

On 06/26/2014 03:49 PM, Heikki Linnakangas wrote:
> On 06/25/2014 05:26 PM, Craig Ringer wrote:
>> Please merge branch fix-syswow64-msdtc from my repo at
>> https://github.com/ringerc/psqlODBC.git .
> 
> Oh, and while you do that, please avoid creating a merge commit. I hate
> those merge commits when I browse the git history, they're just useless
> noise. Please use "git rebase" to clean up the history in your local
> repository first. You can use "git push --dry-run" before the actual
> push to see what will be done. It will print the commit IDs that it
> would push, something like this:
> 
> a87a7dc..de42ed4  master     -> origin/master
> 
> You can then do "git log a87a7dc..de42ed4" to see those commits.
> 
> Also, it would be good to reset the author/committer information in the
> commit before pushing. Looking at the git history the other day, I was
> quite surprised to see commits from Craig, as I didn't know he's a
> psqlodbc committer. Then I realized that you had merged those commits
> from Craig's github repository :-). You can do "git commit --amend
> --reset" to reset them before pushing, but once you do that, should add
> a line in the commit message itself to give credit for the author of the
> patch.
> 
> That's what we do with the PostgreSQL main repository, anyway. We could
> also decide to use the git's Author field to track the original author,
> but at least the Committer field should reflect the actual psqlodbc
> committer. I'm not sure how to change that without changing the Author
> field, though.

I did a little more looking.

It seems the general idea is to retain Author (so what's Committer for?)
and use the Signed-off-by stuff:

author: "git commit -s" (push/pull workflow) or "git format-patch -s"
(email workflow)

committer: "git commit --amend -s" (push/pull workflow) or "git am -s"
(email workflow)

Per:

http://stackoverflow.com/questions/2348911


I guess really it depends on what the history is supposed to be. I'm not
sure core is a good guide here, as the project pretty much adopted a
"git as a better CVS" workflow.

It looks like if you amend / rebase a commit, the committer field is set
to your details, but the author remains the same. That seems appropriate.

-- 
 Craig Ringer                   http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services


-- 
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc



^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: Git history author/committer fields (was Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions)
  2014-06-26 07:49 Git history author/committer fields (was Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions) Heikki Linnakangas <hlinnakangas@vmware.com>
@ 2014-06-27 04:04 ` Inoue, Hiroshi <inoue@tpf.co.jp>
  2014-06-27 07:20   ` Re: Git history author/committer fields (was Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions) Heikki Linnakangas <hlinnakangas@vmware.com>
  2 siblings, 1 reply; 5+ messages in thread

From: Inoue, Hiroshi @ 2014-06-27 04:04 UTC (permalink / raw)
  To: Heikki Linnakangas <hlinnakangas@vmware.com>; +Cc: Craig Ringer <craig@2ndquadrant.com>; pgsql-odbc

(2014/06/26 16:49), Heikki Linnakangas wrote:
> On 06/25/2014 05:26 PM, Craig Ringer wrote:
>> Please merge branch fix-syswow64-msdtc from my repo at
>> https://github.com/ringerc/psqlODBC.git .
>
> Oh, and while you do that, please avoid creating a merge commit. I hate
> those merge commits when I browse the git history, they're just useless
> noise. Please use "git rebase" to clean up the history in your local
> repository first.

Hmm I'm using rebase when pulling from origin/master and using merge
when pulling from other branches. Is there a better way?
Is using merge with --ff-only option a better way as Craig mentioned?

 > You can use "git push --dry-run" before the actual
> push to see what will be done. It will print the commit IDs that it
> would push, something like this:
>
> a87a7dc..de42ed4  master     -> origin/master
>
> You can then do "git log a87a7dc..de42ed4" to see those commits.

OK thanks.

> Also, it would be good to reset the author/committer information in the
> commit before pushing. Looking at the git history the other day, I was
> quite surprised to see commits from Craig, as I didn't know he's a
> psqlodbc committer. Then I realized that you had merged those commits
> from Craig's github repository :-). You can do "git commit --amend
> --reset" to reset them before pushing, but once you do that, should add
> a line in the commit message itself to give credit for the author of the
> patch.
>
> That's what we do with the PostgreSQL main repository, anyway. We could
> also decide to use the git's Author field to track the original author,
> but at least the Committer field should reflect the actual psqlodbc
> committer. I'm not sure how to change that without changing the Author
> field, though.

git commit --amend seems to change the Committer field as Craig
mentioned. Is it OK to push the change by Craig with the Author Craig
and the Committer by me?

regards,
Hiroshi Inoue



-- 
I am using the free version of SPAMfighter.
SPAMfighter has removed 11136 of my spam emails to date.
Get the free SPAMfighter here: http://www.spamfighter.com/len

Do you have a slow PC? Try a Free scan 
http://www.spamfighter.com/SLOW-PCfighter?cid=sigen



-- 
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc



^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: Git history author/committer fields (was Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions)
  2014-06-26 07:49 Git history author/committer fields (was Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions) Heikki Linnakangas <hlinnakangas@vmware.com>
  2014-06-27 04:04 ` Re: Git history author/committer fields (was Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions) Inoue, Hiroshi <inoue@tpf.co.jp>
@ 2014-06-27 07:20   ` Heikki Linnakangas <hlinnakangas@vmware.com>
  0 siblings, 0 replies; 5+ messages in thread

From: Heikki Linnakangas @ 2014-06-27 07:20 UTC (permalink / raw)
  To: Inoue, Hiroshi <inoue@tpf.co.jp>; +Cc: Craig Ringer <craig@2ndquadrant.com>; pgsql-odbc

On 06/27/2014 07:04 AM, Inoue, Hiroshi wrote:
> (2014/06/26 16:49), Heikki Linnakangas wrote:
>> On 06/25/2014 05:26 PM, Craig Ringer wrote:
>>> Please merge branch fix-syswow64-msdtc from my repo at
>>> https://github.com/ringerc/psqlODBC.git .
>>
>> Oh, and while you do that, please avoid creating a merge commit. I hate
>> those merge commits when I browse the git history, they're just useless
>> noise. Please use "git rebase" to clean up the history in your local
>> repository first.
>
> Hmm I'm using rebase when pulling from origin/master and using merge
> when pulling from other branches. Is there a better way?
> Is using merge with --ff-only option a better way as Craig mentioned?

Hmm. I think you can rebase over origin/master after merging Craig's 
branch. That should remove the merge commit.

>> Also, it would be good to reset the author/committer information in the
>> commit before pushing. Looking at the git history the other day, I was
>> quite surprised to see commits from Craig, as I didn't know he's a
>> psqlodbc committer. Then I realized that you had merged those commits
>> from Craig's github repository :-). You can do "git commit --amend
>> --reset" to reset them before pushing, but once you do that, should add
>> a line in the commit message itself to give credit for the author of the
>> patch.
>>
>> That's what we do with the PostgreSQL main repository, anyway. We could
>> also decide to use the git's Author field to track the original author,
>> but at least the Committer field should reflect the actual psqlodbc
>> committer. I'm not sure how to change that without changing the Author
>> field, though.
>
> git commit --amend seems to change the Committer field as Craig
> mentioned. Is it OK to push the change by Craig with the Author Craig
> and the Committer by me?

Fine with me.

- Heikki


-- 
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc



^ permalink  raw  reply  [nested|flat] 5+ messages in thread


end of thread, other threads:[~2014-06-27 07:20 UTC | newest]

Thread overview: 5+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2014-06-26 07:49 Git history author/committer fields (was Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions) Heikki Linnakangas <hlinnakangas@vmware.com>
2014-06-26 08:15 ` Craig Ringer <craig@2ndquadrant.com>
2014-06-26 08:32 ` Craig Ringer <craig@2ndquadrant.com>
2014-06-27 04:04 ` Inoue, Hiroshi <inoue@tpf.co.jp>
2014-06-27 07:20   ` Heikki Linnakangas <hlinnakangas@vmware.com>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox