Skip to Content.
Sympa Menu

freetds - Re: [freetds] git overnight process

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "Craig A. Berry" <craigberry AT mac.com>
  • To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
  • Subject: Re: [freetds] git overnight process
  • Date: Thu, 04 Oct 2012 15:38:56 -0500


On Oct 4, 2012, at 1:53 AM, Frediano Ziglio wrote:

> 2012/10/4 James K. Lowden <jklowden AT freetds.org>:
>> On Wed, 03 Oct 2012 18:05:29 +0000 (GMT)
>> "Craig A. Berry" <craigberry AT mac.com> wrote:
>>
>>> git reset --hard origin/master
>>>
>>> should do the trick assuming you want to throw away local changes to
>>> configure.ac and get into exactly the same state as the remote
>>> repository.
>>
>> Thank you kindly, captain. This is the nightly tarballer; the local
>> changes are a result of munging configure.ac the night before with the
>> current mumble git number revision thing. Absolutely fine to discard
>> and replace (and repatch) with the server's version.
>>
>> --hard
>> Matches the working tree and index to that of the tree being
>> switched to. Any changes to tracked files in the working
>> tree since <commit> are lost.
>>
>> I read that before posting. "the tree being switched to" didn't sound
>> like what I wanted. It's the same old tree, possibly updated a
>> little.
>>
>> Regards,
>>
>> --jkl
>
> Well, just a "git reset --hard" will do the trick as this does not
> change your branch but just discard any changes you made from HEAD.
>

Yes, that should be sufficient in this case. But specifying the remote
branch is a habit I've picked up to make sure I throw away any local,
unpushed commits as well as any uncommitted changes. In other words, it's
not just going back to the local HEAD that I may have messed with in ways I
no longer wish to pursue, but to the upstream HEAD that represents something
I trust more than my local repository.

________________________________________
Craig A. Berry
mailto:craigberry AT mac.com

"... getting out of a sonnet is much more
difficult than getting in."
Brad Leithauser





Archive powered by MHonArc 2.6.24.

Top of Page