[ros-dev] GIT mirror
Alex Ionescu
ionucu at videotron.ca
Thu Jan 8 20:36:31 CET 2009
Hg.
Best regards,
Alex Ionescu
On Thu, Jan 8, 2009 at 12:12 PM, Alexander Potashev <aspotashev at gmail.com>wrote:
> Hi, All!
>
> On 16:34 Thu 08 Jan , Colin Finck wrote:
> > Aleksey Bragin wrote:
> > > Since Arty just mentioned GIT, I think it's about time to uncover a
> > > ReactOS GIT mirror I've been setting up recent couple of weeks.
> >
> > The SVN branches are still missing there. Any way to readd them properly?
> > :-)
>
> I have just realized that it's possible! The problem is that the
> branches in the repository at git://git.reactos.org/ are 'remote
> branches',
> i.e. the are situated in .git/refs/remotes/ (even in the "main"
> repository!). That's a big problem for gitweb, because it only shows the
> branches in '.git/refs/heads/'.
>
> Solution 1:
> Make Aleksey tidy up the repo so that it would have the svn
> branches as its local branches:
> (in the repo at git://git.reactos.org/)
> git checkout origin/<branch>
> git checkout -b local-<branch> # this creates a local
> branch
> But there are some issues regarding this solution:
> 1. it needs 'git pull ...' (frankly, a bit more
> complex command...) in crontab
> 2. there could be some problems with ambiguous branch
> names if you want to exactly keep the names of branches
> in svn.
> However, there's a ugly hack: to copy refs from
> .git/refs/remotes/ to .git/refs/heads (they should be also
> updated after every svn update)
>
> Solution 2: (to not annoy Aleksey ;) )
> This is not a bad solution, it just won't fix gitweb (althought,
> Aleksey says that branches in gitweb are redundant).
>
> The solution is to fetch branches from .git/refs/remotes/ in the
> "main" repository too (not only from .git/refs/heads/):
> add the following line to .git/config in your local repo under
> "[remote "origin"]" section:
> fetch = +refs/remotes/*:refs/remotes/origin/*
> (now there should be two "fetch" lines)
>
>
> Now, to switch to a branch: (say, "xen")
> git checkout origin/xen
>
> Please note, that origin/xen is a remote branch, you can't do
> some operations on it (you can't commit AFAIK, ...). So, if you
> want to start working from the origin/xen branch, you firstly
> need to create a local branch (Git reminds about that):
> git checkout -b xen
> Now you can say 'git branch' to see you brand new branch.
>
>
> (especially to Aleksey)
> I really don't know whether it's possible to push the changes back to
> the svn repo through our Git mirror, but I'm affraid, the answer is
> "NO!!!". It seems that you should import the svn repo directly to push
> back into it.
>
> 'git checkout' is really painful to write every time, so you can add an
> alias (to ~/.gitconfig for user-wide alias), I have the following
> aliases:
> [alias]
> br = branch
> co = checkout
> ci = commit --verbose # --verbose shows the commit
> diff when commiting
> st = status -uall
> di = diff # I have no idea why is it
> in my .gitconfig, I don't use it ;)
>
>
> >
> > Best regards,
> >
> > Colin
> >
> > _______________________________________________
> > Ros-dev mailing list
> > Ros-dev at reactos.org
> > http://www.reactos.org/mailman/listinfo/ros-dev
> I really hate this Ros-dev ML ;), there even no information on how to
> unsubscribe (which may be necessary on LKML ;))
>
> Alexander
> _______________________________________________
> Ros-dev mailing list
> Ros-dev at reactos.org
> http://www.reactos.org/mailman/listinfo/ros-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.reactos.org/pipermail/ros-dev/attachments/20090108/74f59a20/attachment-0001.html
More information about the Ros-dev
mailing list