# undo delete of remote-tracking branch

3 messages from 2010-01-19 to 2010-01-19. Participants: Leonardo Boiko, Shawn O. Pearce.
Thread: https://gitlist.dev/t/22291

## Leonardo Boiko, 2010-01-19 15:40

Subject: undo delete of remote-tracking branch
Message-ID: <87bpgqnlws.wl%leoboiko@ime.usp.br>
URL: https://gitlist.dev/e/87bpgqnlws.wl%25leoboiko%40ime.usp.br

```

Hi,

I'm a complete idiot and just typed this:

    git branch -d -r origin/master

Is there a way to undo my act of idiocy?

--
Leonardo Boiko

```

## Shawn O. Pearce, 2010-01-19 15:59

Subject: Re: undo delete of remote-tracking branch
Message-ID: <20100119155911.GC23466@spearce.org>
URL: https://gitlist.dev/e/20100119155911.GC23466%40spearce.org
In-Reply-To: <87bpgqnlws.wl%leoboiko@ime.usp.br>

```
Leonardo Boiko <leoboiko@ime.usp.br> wrote:
> I'm a complete idiot and just typed this:
> 
>     git branch -d -r origin/master
> 
> Is there a way to undo my act of idiocy?

git fetch origin

Which will create it again during the fetch cycle.  Unfortunately
the reflog for origin/master is gone, so you won't get results for
origin/master@{4.days.ago}.

-- 
Shawn.

```

## Leonardo Boiko, 2010-01-19 16:08

Subject: Re: undo delete of remote-tracking branch
Message-ID: <878wbunkm3.wl%leoboiko@ime.usp.br>
URL: https://gitlist.dev/e/878wbunkm3.wl%25leoboiko%40ime.usp.br
In-Reply-To: <20100119155911.GC23466@spearce.org>

```
At Tue, 19 Jan 2010 07:59:11 -0800, Shawn O. Pearce wrote:
> git fetch origin

Thanks much, that solved the problem.  Will try to educate myself
better on remote-tracking branches.

```
