[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: VC mode and git

From: Dmitry Gutov
Subject: Re: VC mode and git
Date: Thu, 26 Mar 2015 19:07:42 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:36.0) Gecko/20100101 Thunderbird/36.0

On 03/26/2015 06:59 PM, Eli Zaretskii wrote:

in .git/hooks/post-commit/.

What happens if the commit succeed, but the push in the hook fails?
Will Git roll back the commit?

Nope, unless you ask it.

If not, then this isn't reallt a good emulation of bzr's bound
branches, because there a commit+push was an atomic operation: either
both succeeded, or none at all.

Maybe you should try something like:

git push || git reset HEAD^

(100% untested).

reply via email to

[Prev in Thread] Current Thread [Next in Thread]