# git-svn wowes

3 messages from 2009-07-22 to 2009-07-23. Participants: Aaron Gray, Sverre Rabbelier, Eric Wong.
Thread: https://gitlist.dev/t/20194

## Aaron Gray, 2009-07-22 13:55

Subject: git-svn wowes
Message-ID: <025FAAA7CA644D709E1635C497753444@HPLAPTOP>
URL: https://gitlist.dev/e/025FAAA7CA644D709E1635C497753444%40HPLAPTOP

```
Hi,

I have a working git-svn clone of a svn based project.

At the mement I have a .sh script run every hour which goes :-

    git svn fetch
    git reset -- hard HEAD
    git svn rebase

I am sure this is like using a hammer to crack a nut.

Is there a better way to do this ?

Many thanks in advance,

Aaron

```

## Sverre Rabbelier, 2009-07-22 18:24

Subject: Re: git-svn wowes
Message-ID: <fabb9a1e0907221124u345bc572mfcead0468306b6e5@mail.gmail.com>
URL: https://gitlist.dev/e/fabb9a1e0907221124u345bc572mfcead0468306b6e5%40mail.gmail.com
In-Reply-To: <025FAAA7CA644D709E1635C497753444@HPLAPTOP>

```
Heya,

On Wed, Jul 22, 2009 at 13:55, Aaron
Gray<aaronngray.lists@googlemail.com> wrote:
>   git svn rebase

Should be enough ('git svn rebase' runs 'git svn fetch' first),
assuming you don't touch the working directory, which you probably
don't considering that your script blasts away all changes every hour.

-- 
Cheers,

Sverre Rabbelier

```

## Eric Wong, 2009-07-23 08:12

Subject: Re: git-svn wowes
Message-ID: <20090723081208.GB32287@dcvr.yhbt.net>
URL: https://gitlist.dev/e/20090723081208.GB32287%40dcvr.yhbt.net
In-Reply-To: <025FAAA7CA644D709E1635C497753444@HPLAPTOP>

```
Aaron Gray <aaronngray.lists@googlemail.com> wrote:
> Hi,
>
> I have a working git-svn clone of a svn based project.
>
> At the mement I have a .sh script run every hour which goes :-
>
>    git svn fetch
>    git reset -- hard HEAD
>    git svn rebase
>
> I am sure this is like using a hammer to crack a nut.
>
> Is there a better way to do this ?

Assuming you don't make your own local changes ever:

  git svn fetch
  git reset --hard $ref

Where $ref is most likely "trunk" if you used -s/--stdlayout or
"git-svn" if you did not.  Running `git branch -r' will give you
a list of remote refs that you can reset to.

-- 
Eric Wong

```
