* how to reset to remote repo
@ 2009-02-23 10:55 bill lam
2009-02-23 12:14 ` Dilip M
2009-02-23 12:49 ` Sitaram Chamarty
0 siblings, 2 replies; 6+ messages in thread
From: bill lam @ 2009-02-23 10:55 UTC (permalink / raw)
To: git
I cloned some public git repos and made some local patches. Later I
pulled updates again and that merged with my patches. Now I want to
throw away my patches, how do I get a clean working repo that is a
100% clone of the remote repo?
--
regards,
====================================================
GPG key 1024D/4434BAB3 2008-08-24
gpg --keyserver subkeys.pgp.net --recv-keys 4434BAB3
唐詩285 張祜 集靈臺二首之二
虢國夫人承主恩 平明騎馬入宮門 卻嫌脂粉污顏色 淡掃蛾眉朝至尊
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: how to reset to remote repo
2009-02-23 10:55 how to reset to remote repo bill lam
@ 2009-02-23 12:14 ` Dilip M
2009-02-23 12:49 ` Sitaram Chamarty
1 sibling, 0 replies; 6+ messages in thread
From: Dilip M @ 2009-02-23 12:14 UTC (permalink / raw)
To: git
git reset --hard HEAD
-- BR, Dilip
On Mon, Feb 23, 2009 at 4:25 PM, bill lam <cbill.lam@gmail.com> wrote:
> I cloned some public git repos and made some local patches. Later I
> pulled updates again and that merged with my patches. Now I want to
> throw away my patches, how do I get a clean working repo that is a
> 100% clone of the remote repo?
>
> --
> regards,
> ====================================================
> GPG key 1024D/4434BAB3 2008-08-24
> gpg --keyserver subkeys.pgp.net --recv-keys 4434BAB3
> 唐詩285 張祜 集靈臺二首之二
> 虢國夫人承主恩 平明騎馬入宮門 卻嫌脂粉污顏色 淡掃蛾眉朝至尊
> --
> To unsubscribe from this list: send the line "unsubscribe git" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: how to reset to remote repo
2009-02-23 10:55 how to reset to remote repo bill lam
2009-02-23 12:14 ` Dilip M
@ 2009-02-23 12:49 ` Sitaram Chamarty
2009-02-23 14:57 ` bill lam
1 sibling, 1 reply; 6+ messages in thread
From: Sitaram Chamarty @ 2009-02-23 12:49 UTC (permalink / raw)
To: git
On 2009-02-23, bill lam <cbill.lam@gmail.com> wrote:
> I cloned some public git repos and made some local patches. Later I
> pulled updates again and that merged with my patches. Now I want to
> throw away my patches, how do I get a clean working repo that is a
> 100% clone of the remote repo?
git reset --hard origin/master
This is a very simple question, and may be quicker on irc
:-)
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: how to reset to remote repo
2009-02-23 12:49 ` Sitaram Chamarty
@ 2009-02-23 14:57 ` bill lam
2009-02-23 15:50 ` Sitaram Chamarty
0 siblings, 1 reply; 6+ messages in thread
From: bill lam @ 2009-02-23 14:57 UTC (permalink / raw)
To: Sitaram Chamarty; +Cc: git
On Mon, 23 Feb 2009, Sitaram Chamarty wrote:
> git reset --hard origin/master
>
> This is a very simple question, and may be quicker on irc
> :-)
Does it always work? For example if I already made several patches
interleaved with several fetch/update, or if I rebase to remove the
orgin/master?
--
regards,
====================================================
GPG key 1024D/4434BAB3 2008-08-24
gpg --keyserver subkeys.pgp.net --recv-keys 4434BAB3
唐詩286 張祜 題金陵渡
金陵津渡小山樓 一宿行人自可愁 潮落夜江斜月裡 兩三星火是瓜州
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: how to reset to remote repo
2009-02-23 14:57 ` bill lam
@ 2009-02-23 15:50 ` Sitaram Chamarty
2009-02-23 23:19 ` bill lam
0 siblings, 1 reply; 6+ messages in thread
From: Sitaram Chamarty @ 2009-02-23 15:50 UTC (permalink / raw)
To: git
On 2009-02-23, bill lam <cbill.lam@gmail.com> wrote:
> On Mon, 23 Feb 2009, Sitaram Chamarty wrote:
>> git reset --hard origin/master
>>
>> This is a very simple question, and may be quicker on irc
>> :-)
>
> Does it always work? For example if I already made several patches
> interleaved with several fetch/update, or if I rebase to remove the
> orgin/master?
I'm not sure why a rebase of any kind would remove a remote
brancg but you can always do 'git fetch' first if you
accidentally messed up origin/master.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: how to reset to remote repo
2009-02-23 15:50 ` Sitaram Chamarty
@ 2009-02-23 23:19 ` bill lam
0 siblings, 0 replies; 6+ messages in thread
From: bill lam @ 2009-02-23 23:19 UTC (permalink / raw)
To: Sitaram Chamarty; +Cc: git
On Mon, 23 Feb 2009, Sitaram Chamarty wrote:
> I'm not sure why a rebase of any kind would remove a remote
> brancg but you can always do 'git fetch' first if you
> accidentally messed up origin/master.
Thanks. Incidentally I just found that I could git reset just before
my first patch and then git pull again.
--
regards,
====================================================
GPG key 1024D/4434BAB3 2008-08-24
gpg --keyserver subkeys.pgp.net --recv-keys 4434BAB3
唐詩226 王維 送別
山中相送罷 日暮掩柴扉 春草明年綠 王孫歸不歸
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2009-02-23 23:21 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-02-23 10:55 how to reset to remote repo bill lam
2009-02-23 12:14 ` Dilip M
2009-02-23 12:49 ` Sitaram Chamarty
2009-02-23 14:57 ` bill lam
2009-02-23 15:50 ` Sitaram Chamarty
2009-02-23 23:19 ` bill lam
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).