Problem adding and updating mirrors.
Reported by misaka | June 26th, 2008 @ 03:18 PM | in 0.5
When running git on certain platforms (presumably not the author's platform), git ends up being turned into a backgrounded process causing fun and mayhem for all. My platform is Ubuntu 8.4 and the problem looks a little something like this:
dev:~/Source/git/Test$ braid add --type git ssh://git.migapps.com/git/tztime vendor/plugins/tztime
Checking out 'braid/track'.
Adding git mirror of 'ssh://git.migapps.com/git/tztime', branch 'master'.
Setting up remote for 'vendor/plugins/tztime/'.
Fetching data from 'braid/git/vendor/plugins/tztime/master'.
Error occured: fatal: ambiguous argument 'braid/git/vendor/plugins/tztime/master': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions
Resetting 'braid/track' to '80671b7715161971cbe51a35d16ffbc406e81296'.
Checking out 'master'.
dev:~/Source/git/Test$ error: refs/remotes/braid/git/vendor/plugins/tztime/master/HEAD points nowhere!
warning: no common commits
remote: Counting objects: 13, done.
remote: Compressing objects: 100% (13/13), done.
remote: Total 13 (delta 2), reused 0 (delta 0)
Unpacking objects: 100% (13/13), done.
From ssh://git.migapps.com/git/tztime
* [new branch] master -> braid/git/vendor/plugins/tztime/master/master
You can see that my command-prompt came back right after "Checking out 'master'.", and that git finished after that. This problem can be overcome on the 'add', braid can be run twice, but updates seem to be a dead-end.
The problem seems to be on line 18 of lib/braid/operations.rb where git is invoked like so:
git fetch -n #{remote} &> /dev/null
Some systems will run this through sh which does not understand &> (even when run in bash compatibility mode presumably). Best way to fix this is to probably change this to:
git fetch -n #{remote} 2>&1 > /dev/null
I've included a patch to that effect.
HTH
Comments and changes to this ticket
-

misaka June 26th, 2008 @ 08:25 PM
Just noticed that this is also a problem in git_svn_fetch, line 102 in the same file.
-
Norbert Crombach July 17th, 2008 @ 02:03 AM
- → Tag changed from to bug fetch system
- → Milestone changed from to 0.5
- → Assigned user changed from to Norbert Crombach
Once again thanks for the fixes, I will merge this before the 0.5 release.
-

Tyler Rick September 18th, 2008 @ 10:58 AM
- → Tag changed from bug fetch system to bug fetch system
Yeah, I'm experiencing pretty much the same problem on my (Ubuntu 8.4) system. It goes to the background and fails (doesn't create the merge commit) and then it gets stuck in some confused and messed up state...
> braid add -p git://github.com/cjbottaro/app_config.git Adding git mirror of 'git://github.com/cjbottaro/app_config.git'. Setting up remote for 'vendor/plugins/app_config/'. Resetting to '82b9acc'. Error: unknown revision: braid/vendor/plugins/app-config > error: refs/remotes/braid/vendor/plugins/app-config/HEAD points nowhere! > warning: no common commits remote: Counting objects: 17, done. remote: Compressing objects: 10remote: 0% (10/10), done. remote: Total 17 (delta 0), reused 0 (delta 0) Unpacking objects: 100% (17/17), done. From git://github.com/cjbottaro/app_config * [new branch] master -> braid/vendor/plugins/app-config/masterThanks misaka for the fix, that worked for me too, although my patch looks a little bit different.
I hope development on this has not ceased, looks like it's been a while and the latest release is still 0.4.9...
-

Tyler Rick September 18th, 2008 @ 11:04 AM
- no changes were found...
-
-

-
-
Fredrik Bränström October 28th, 2008 @ 06:43 AM
I think I'm experiencing this issue, or something like it:
http://pastie.org/private/yivily...
Can't add mirror. I accidentally put it in vendor/ instead of in vendor/plugins but that's beside the point. (Btw, to move it, do I have to remove & add it back, or can I just edit .braids or something?)
-
Cristi Balan October 28th, 2008 @ 11:23 AM
Fredrik,
Those are just warning and progress messages from git. The mirror should have been added correctly. You can use git log to confirm this. You should have a "Add mirror 'vendor/vendor/attachment_fu'" as your last commit.
I understand it's confusing so, we'll work on having some messages informing about success of operations.
As for moving a mirror, yes, you'll have o remove/add for now.
Also, you can use braid add somerepo -p to add it as a rails plugin.
-
Norbert Crombach October 28th, 2008 @ 12:53 PM
- → State changed from new to resolved
I think this is done?
Please Login or create a free account to add a new comment.
You can update this ticket by sending an email to from your email client. (help)
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
Braid is a simple tool to help track git and svn vendor branches in a git repository.
