문제

I am a git user but now I need to work on a project that is hosted on launchpad.

I noticed that git and bzr are similar but apparently have some confusing differences.

In git when you clone a remote repo the local copy is automatically hooked to the remote repo url. Apparently this is not the case in Bzr.

So how do I add the remote URL in bzr? In git I would do something like this:

git remote add origin git@github.com:bar/foo.git
도움이 되었습니까?

해결책

When you use bzr branch lp:project that sets the parent branch for the local repo to the URL you specified. bzr pull will automatically use the parent branch, but bzr push requires that you specify the parent if you want to push to the parent, like so: bzr push :parent. You can add the --remember option to the push command to set the push branch so that you don't have to specify the :parent every time. You can see what the parent, push and pull branches are for your local repo using the bzr info command.

다른 팁

In BAZAAR, this operation is called bind.
http://doc.bazaar.canonical.com/beta/en/user-reference/bind-help.html

bzr bind lp:~bzr/bzr-gtk/trunk

When I'm doing a checkout (branch) with TortoiseBzr, my working copy is automaticcaly bind to the branch origin.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top