workaround for the broken aspect of refs/remotes [message #756940] |
Tue, 15 November 2011 10:53  |
Eclipse User |
|
|
|
Currently egit synchronization has a bug in its handling of references in refs/remotes: the plugin assumes these are remote-reference form, which Git does not require. Any files in this directory which are not in remote-reference form will fail when selected for use as the destination in advanced synchronization. One way you can get such files is via svn-bridging, but this is just an example, bridging is not the source of the problem.
Fortunately there's a simple workaround, at least in the unix world: symbolic links. Just make a symlink from the entry in refs/remotes to the the top-level of refs. The link can then be used in advanced synchronization.
For example suppose you have a bridge reference in .git/refs/remotes/trunk. You can't use this directly in advanced synchronization even though it's listed in the menu. Instead do this:
cd .git
ln -s remotes/trunk svn_trunk (or whatever name you want to use)
Now you can do advanced synchronization with refs/svn-trunk as the destination and everything works fine.
Note that it has to be a link, not a copy, otherwise the new reference will never be updated.
Probably there's a Windows equivalent but I don't know what it is.
|
|
|
|
|
Re: workaround for the broken aspect of refs/remotes [message #759009 is a reply to message #758117] |
Fri, 25 November 2011 10:01  |
Eclipse User |
|
|
|
Thank you for pointing out the the first parameter to git symbolic-ref can be an arbitrary path. As I mentioned, I only just found this command and that feature wasn't obvious from the help page.
Are symbolic references a 'stupid' concept? <shrug>. Stupid or not, at least this provides a workaround for the Advanced Synchronization refs/remotes bug. Otherwise my team wouldn't be able to make any effective use of Advanced Synchronization at all. This way they can.
|
|
|
Powered by
FUDForum. Page generated in 0.24415 seconds