Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: MythTV: Dev
Re: GIT reverts accidentally committed
 

Index | Next | Previous | View Flat


danielk at cuymedia

Feb 22, 2012, 1:38 PM


Views: 735
Permalink
Re: GIT reverts accidentally committed [In reply to]

On Wed, 2012-02-22 at 10:52 +1100, Nigel Pearson wrote:
> >> % git reset --hard a5fcdea9779f8ad1821ee741fe99c9032c2c51a6
> >> HEAD is now at a5fcdea don't let stash cause failures
> >> % git push -f
> ...
> >> To git [at] github:MythTV/packaging.git
> >> + 30acaf3...a5fcdea master -> master (forced update)
> >
> > GAH! This is the way to clean it up, yes, but now you have buggered
> > up everyone who has downloaded with your errant changes in there.
>
>
> Oops. Do "git pull"s now fail?

Yeah, anyone that pulled the bad change has to manually repair their
repo. The proper thing to do is to just reverse all the changes. As
you found out git revert has problems if there is a merge involved
because it doesn't know which parent tree is 'trunk'; but it is still
possible to create a patch manually. (There is probably some git magic
to tell revert what to do, but I don't know it.)

As a rule you should only get rid of commits completely while they
are still only in your local tree. After that you want to commit
something new to do undo the damage.

-- Daniel

_______________________________________________
mythtv-dev mailing list
mythtv-dev [at] mythtv
http://www.mythtv.org/mailman/listinfo/mythtv-dev

Subject User Time
GIT reverts accidentally committed nigel at ind Feb 21, 2012, 3:48 AM
    Re: GIT reverts accidentally committed jyavenard at gmail Feb 21, 2012, 3:53 AM
    Re: GIT reverts accidentally committed jyavenard at gmail Feb 21, 2012, 3:54 AM
    Re: GIT reverts accidentally committed jyavenard at gmail Feb 21, 2012, 3:56 AM
    Re: GIT reverts accidentally committed mtdean at thirdcontact Feb 21, 2012, 12:59 PM
    Re: GIT reverts accidentally committed nigel at ind Feb 21, 2012, 2:40 PM
    Re: GIT reverts accidentally committed nigel at ind Feb 21, 2012, 3:15 PM
    Re: GIT reverts accidentally committed gjhurlbu at gmail Feb 21, 2012, 3:35 PM
    Re: GIT reverts accidentally committed nigel at ind Feb 21, 2012, 3:52 PM
    Re: GIT reverts accidentally committed jyavenard at gmail Feb 21, 2012, 3:54 PM
    Re: GIT reverts accidentally committed gjhurlbu at gmail Feb 21, 2012, 4:05 PM
    Re: GIT reverts accidentally committed jyavenard at gmail Feb 21, 2012, 4:08 PM
    Re: GIT reverts accidentally committed gjhurlbu at gmail Feb 21, 2012, 4:11 PM
    Re: GIT reverts accidentally committed nigel at ind Feb 21, 2012, 4:22 PM
    Re: GIT reverts accidentally committed lists at glidos Feb 22, 2012, 2:33 AM
    Re: GIT reverts accidentally committed danielk at cuymedia Feb 22, 2012, 1:38 PM
        Re: GIT reverts accidentally committed lsorense at csclub Feb 22, 2012, 1:50 PM
        Re: GIT reverts accidentally committed ijc at hellion Feb 23, 2012, 3:56 AM

  Index | Next | Previous | View Flat
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.