threads / discuss / 20957

Pair Programming Workflow Suggestions

Subject: Pair Programming Workflow Suggestions

## tl;dr

7 messages between Sep 15, 2009 and Sep 20, 2009.

replies: 6people: 4as markdown or json

Tim Visher· Sep 15, 2009, 17:43 UTC · lore
Hello Everyone,

I'm interested in hearing how people use Git for pair programming. Specifically, how do you document that you are programming in pairs. Typically, of course, you have a driver and a navigator. It seems natural to have a commit's author be the driver at the time, but that doesn't seem to do justice to what pair programming is. Really, both people are normally coding, but one person is doing the typing and most of the thinking while the other is acting as an in place code reviewer. There are even cases where there's a third person involved.

I did find [Brian Helmkamp's script](http://www.brynary.com/2008/9/1/setting-the-git-commit-author-to-pair-programmers-names) but that's not really what I'm looking for. For instance, that would break the nice integration we have with Hudson at this point for displaying when a developer was last active. It would be nicer to have an arbitrary number of authors that can all exist separately, but I'm fairly certain that git does not support that.

Thoughts?
-- 
In Christ,

Timmy V.

http://burningones.com/
http://five.sentenc.es/ - Spend less time on e-mail
Sean Estabrooks· Sep 15, 2009, 18:14 UTC · re: Tim Visher · lore

Re: Pair Programming Workflow Suggestions

On Tue, 15 Sep 2009 13:43:17 -0400 Tim Visher <tim.visher@gmail.com> wrote:

[...]
> It would be nicer to
> have an arbitrary number of authors that can all exist separately, but
> I'm fairly certain that git does not support that.
Tim,

If you're just looking for a way to quickly switch the author information quickly between individual commits. You could create a shell alias for each of the programmers that does:

   export GIT_AUTHOR_NAME="some name" GIT_AUTHOR_EMAIL="name@where.com"

This will override the global and per repo configured author information for all subsequent commits.

HTH, Sean

Tim Visher· Sep 16, 2009, 13:35 UTC · re: Sean Estabrooks · lore

Re: Pair Programming Workflow Suggestions

On Tue, Sep 15, 2009 at 2:14 PM, Sean Estabrooks <seanlkml@sympatico.ca> wrote:
Show 18 quoted lines
> On Tue, 15 Sep 2009 13:43:17 -0400
> Tim Visher <tim.visher@gmail.com> wrote:
>
> [...]
>> It would be nicer to
>> have an arbitrary number of authors that can all exist separately, but
>> I'm fairly certain that git does not support that.
>
> Tim,
>
> If you're just looking for a way to quickly switch the author information
> quickly between individual commits.  You could create a shell alias for
> each of the programmers that does:
>
>   export GIT_AUTHOR_NAME="some name" GIT_AUTHOR_EMAIL="name@where.com"
>
> This will override the global and per repo configured author information
> for all subsequent commits.

That is an interesting idea. My point is really that having a committer and an author is something that makes sense in terms of non-pairing. Especially in the OS world where developers may never even get to meet, let alone code together, one developer writes a feature somewhere and then submits it to the maintainer and the maintainer puts it in. Pairing, on the other hand, is much more tightly integrated than that. Just like in Brian's post, it's really a situation of Dev1 _&_ Dev2 wrote this feature, but one of them happened to be typing and doing most of the nitty-gritty developing. Changing the authors between committs almost seems to introduce an arbitrary level of distinction where it's no longer _both_ but _one then the other_. Does that make my question any clearer?

-- 
In Christ,

Timmy V.

http://burningones.com/
http://five.sentenc.es/ - Spend less time on e-mail
Nicolas Sebrecht· Sep 16, 2009, 14:17 UTC · re: Tim Visher · lore

Re: Pair Programming Workflow Suggestions

The 16/09/09, Tim Visher wrote:
Show 8 quoted lines
> 
>                         Pairing, on the other hand, is much more
> tightly integrated than that.  Just like in Brian's post, it's really
> a situation of Dev1 _&_ Dev2 wrote this feature, but one of them
> happened to be typing and doing most of the nitty-gritty developing.
> Changing the authors between committs almost seems to introduce an
> arbitrary level of distinction where it's no longer _both_ but _one
> then the other_.  Does that make my question any clearer?

FMPOV (and to follow the Pair Programming purpose), there isn't an "I" in "Pair". So having the same author name and sign-off for each pair is what makes most sense. IMHO, "dev1_and_dev2" is actually the best option.

-- 
Nicolas Sebrecht
Tim Visher· Sep 20, 2009, 15:37 UTC · re: Nicolas Sebrecht · lore

Re: Pair Programming Workflow Suggestions

On Wed, Sep 16, 2009 at 10:17 AM, Nicolas Sebrecht <nicolas.s.dev@gmx.fr> wrote:
Show 14 quoted lines
> The 16/09/09, Tim Visher wrote:
>>
>>                         Pairing, on the other hand, is much more
>> tightly integrated than that.  Just like in Brian's post, it's really
>> a situation of Dev1 _&_ Dev2 wrote this feature, but one of them
>> happened to be typing and doing most of the nitty-gritty developing.
>> Changing the authors between committs almost seems to introduce an
>> arbitrary level of distinction where it's no longer _both_ but _one
>> then the other_.  Does that make my question any clearer?
>
> FMPOV (and to follow the Pair Programming purpose), there isn't an "I"
> in "Pair".  So having the same author name and sign-off for each pair is
> what makes most sense. IMHO, "dev1_and_dev2" is actually the best
> option.

That's certainly interesting. I guess I just assumed, not having too much practical experience with actually pairing, that the driver would be doing most of the coding for a given commit… It's true that that's not really the case.

Do you guys use Hudson or something similar when you're pairing? How's your experience regarding how it interoperates with the dev_1_and_dev_2 naming convention?

-- 
In Christ,

Timmy V.

http://burningones.com/
http://five.sentenc.es/ - Spend less time on e-mail
Jakub Narebski· Sep 15, 2009, 18:20 UTC · re: Tim Visher · lore

Re: Pair Programming Workflow Suggestions

Tim Visher <tim.visher@gmail.com> writes:
> I'm interested in hearing how people use Git for pair programming.
> Specifically, how do you document that you are programming in pairs.
[...]
> I did find Brian Helmkamp's script
> http://www.brynary.com/2008/9/1/setting-the-git-commit-author-to-pair-programmers-names
> but that's not really what I'm looking for. [...]

I'm not sure if this would help you, but take a look at "Pair Programming & git & github & Gravatar & You & You" blog post by Jon "Lark" Larkowski from May 30, 2009:

  http://blog.l4rk.com/2009/05/pair-programming-git-github-gravatar.html
-- 
Jakub Narebski
Poland
ShadeHawk on #git
Tim Visher· Sep 16, 2009, 13:36 UTC · re: Jakub Narebski · lore

Re: Pair Programming Workflow Suggestions

On Tue, Sep 15, 2009 at 2:20 PM, Jakub Narebski <jnareb@gmail.com> wrote:
Show 16 quoted lines
> Tim Visher <tim.visher@gmail.com> writes:
>
>> I'm interested in hearing how people use Git for pair programming.
>> Specifically, how do you document that you are programming in pairs.
>
> [...]
>
>> I did find Brian Helmkamp's script
>> http://www.brynary.com/2008/9/1/setting-the-git-commit-author-to-pair-programmers-names
>> but that's not really what I'm looking for. [...]
>
> I'm not sure if this would help you, but take a look at "Pair
> Programming & git & github & Gravatar & You & You" blog post by Jon
> "Lark" Larkowski from May 30, 2009:
>
>  http://blog.l4rk.com/2009/05/pair-programming-git-github-gravatar.html

Unfortunately my company firewall is blocking that post. I'll have to read it later. Thanks for the pointer though!

-- 
In Christ,

Timmy V.

http://burningones.com/
http://five.sentenc.es/ - Spend less time on e-mail

← back to recent threads