#7 open
Nikhil Gupte

Update tickets only for specific branches

Reported by Nikhil Gupte | January 30th, 2009 @ 07:04 AM | in bugs

Hi,

I've got 3 remote branches - master, staging and production.

Due to this, my LH ticket gets duplicate updates - 1st when I push to my remote master, then when I push to staging and then yet again when I push to the production branch.

Is there any way we can associate a branch on which the LH tickets updates should be triggered?

Thanks.

Comments and changes to this ticket

  • Nikhil Gupte

    Nikhil Gupte January 30th, 2009 @ 07:21 AM

    I managed to use the following work-around in the post-receive hook:

    
    if ref.ends_with?('master')
      Configuration.load(CONFIG_DIR)
      TicketUpdate.new(rev_old, rev_new, ref).parse.send_changes
    end
    
  • gwik

    gwik February 3rd, 2009 @ 10:28 AM

    • State changed from “new” to “open”

    Do you use the merge command to update your stagin and production branches ? If you do it's bug.

    The git --first-parent option I use, should garantee that the updates are not replayed when you push a merge.

    What git version do you use on the remote ?

  • Nikhil Gupte

    Nikhil Gupte February 3rd, 2009 @ 10:37 AM

    My git version is 1.6.1 (local and remote)

    I have local mater, production and staging branches and the same on remote.

    I make changes to master, push to my remote master for my colleagues. Once a bunch of changes are done, I merge local master into my local staging which then I push to my remote staging. Once QA approves of staging, I merge my local staging into my local production and push it to my remote production.

    I got around the problem of multiple updates to my LH tickets by only passing the commits on the remote master to the hook.

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

http://github.com/gwik/lighthouse-git-hooks

Shared Ticket Bins

People watching this ticket

Tags

Pages