<div dir="ltr">Hi All,<br><div class="gmail_extra"><br></div><div class="gmail_extra">Here are some commands to make a "full" git repo, from the "trunk" repo<br></div><div class="gmail_extra">(the only complaint that everyone agrees on)<br></div><div class="gmail_extra">We keep git commit sha's for the trunk, and we add all branches/tags<br><br></div><div class="gmail_extra">It needs some more tunning, but it's a good start :)<br><br></div><div class="gmail_extra">1) clone the trunk repo<br>git clone git://<a href="http://git.openwrt.org/openwrt.git">git.openwrt.org/openwrt.git</a> openwrt-git-svn<br></div><div class="gmail_extra">cd openwrt-git-svn</div><div class="gmail_extra"><br></div><div class="gmail_extra">2) init git svn<br>git svn init -T"/trunk" -t"/tags" -b"/branches" --prefix="svn/" svn://<a href="http://svn.openwrt.org/openwrt">svn.openwrt.org/openwrt</a><br><br></div><div class="gmail_extra">3) tell git that we already have trunk<br>git update-ref refs/remotes/svn/trunk refs/remotes/origin/master<br></div><div class="gmail_extra"><br></div><div class="gmail_extra">4) download all branches/tags (except trunk because we already have it)<br></div><div class="gmail_extra">git svn fetch<br><br></div><div class="gmail_extra">resulting .git/config<br><blockquote style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex" class="gmail_quote">[core]<br>        repositoryformatversion = 0<br>        filemode = true<br>        bare = false<br>        logallrefupdates = true<br>[remote "origin"]<br>        url = git://<a href="http://git.openwrt.org/openwrt.git">git.openwrt.org/openwrt.git</a><br>        fetch = +refs/heads/*:refs/remotes/origin/*<br>[branch "master"]<br>        remote = origin<br>        merge = refs/heads/master<br>[svn-remote "svn"]<br>        url = svn://<a href="http://svn.openwrt.org/openwrt">svn.openwrt.org/openwrt</a><br>        fetch = trunk:refs/remotes/svn/trunk<br>        branches = branches/*:refs/remotes/svn/*<br>        tags = tags/*:refs/remotes/svn/tags/*<br></blockquote><br></div><div class="gmail_extra"><br></div><div class="gmail_extra">original SO post: <a href="http://stackoverflow.com/a/12251845">http://stackoverflow.com/a/12251845</a><br><br></div><div class="gmail_extra">Good night<br></div><div class="gmail_extra">Etienne<br></div></div>