Thread (1 message) 1 message, 1 author, 2016-06-15

Re: why is git destructive by default? (i suggest it not be!)

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:44:49

Jakub Narebski [off-list ref] writes:
On Wed, 25 Jun 2008, Theodore Tso wrote:
quoted
The reason why I've been thinking that I should change my shell script
from:

        git checkout integration
        git reset --hard <foo>

to:

        git update-ref ref/heads/integration HEAD
        git checkout integration
Hmmmm.... Wouldn't it be easier on fingers to use

          git reset --soft integration
That does not do anything close to what Ted is doing, does it?

Anyway, here is how I conclude my git day:

	git checkout next
        ... merge more and test
        ... be happy that next is in very good shape ;-)
        git branch -f pu
        git checkout pu
        git merge ... merge other topics to rebuild pu
        git merge ...
        ...

which is probably a bit less error prone then update-ref, if you type from
the command line like I do.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help