bzr checkout 与 bzr get
之间有什么区别
bzr checkout ./MyProject MyProject.dev
# later followed by a
cd MyProject.dev
bzr pull ../MyProject
我想知道和
bzr get ./MyProject MyProject.dev
# later followed by
cd MyProject.dev
bzr pull
据我所知,唯一的区别是:
bzr get
设置拉取位置。bzr checkout
未设置拉取 位置,所以必须指定 第一次拉的时候。
还有其他区别吗?
I wonder what the difference is between
bzr checkout ./MyProject MyProject.dev
# later followed by a
cd MyProject.dev
bzr pull ../MyProject
and
bzr get ./MyProject MyProject.dev
# later followed by
cd MyProject.dev
bzr pull
As far I can tell the only difference is:
bzr get
sets the pull location.bzr checkout
doesn't set the pull
location, so it must be specified
the first time you pull.
Are there other differences?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(4)
对于
bzr checkout
,您不应使用bzr pull
,而应使用bzr update
。bzr get
是bzrbranch
的别名,大致相当于git clone
。In the case of
bzr checkout
you should not usebzr pull
, but should usebzr update
instead.bzr get
is alias ofbzr branch
which is roughly equivalent ofgit clone
.bzr get
创建分支,而bzr checkout
创建结帐。通过签出,您提交给MyProject.dev
的任何修订也将提交给MyProject
。有关更多详细信息,请参阅结账教程。
bzr get
creates a branch, whereasbzr checkout
creates a checkout. With a checkout, any revisions you commit toMyProject.dev
will also be committed toMyProject
.For more detail, see the checkout tutorial.
这是 Bazaar 的一项很酷的功能,但没有得到足够的关注:人们能够以让自己舒服的方式工作,即使在同一个共享存储库上也是如此。
有 git 或其他 DVCS 爱好者吗?美好的。让他们使用 bzr 分支。
是否有一些老派的 svn 人员无法理解所有的分支和合并? “等等...我必须创建一个分支,进行提交,然后合并我的分支,然后推送我的分支?太愚蠢了,我只想提交!”美好的。让他们使用 bzr checkout 进行操作。
尽管 git 更加流行且速度更快,但这种灵活性正是 Bazaar 吸引我的地方。
This is one of the way cool features of Bazaar that doesn't get enough press: the ability for people to work the way that makes them comfortable, even on the same shared repository.
Have some git or other DVCS devotees? Fine. Have them use bzr branch.
Have some old-school svn guys who just can't wrap their heads around all the branching and merging? "Wait...I have to create a branch, do commits, then merge my branch, then push my branch? How stupid, I just want to commit!" Fine. Have them work with bzr checkout.
This type of flexibility is what draws me to Bazaar, despite the fact that git is wildly more popular and faster.
基本上,您可以选择不绑定到从中获取代码的分支:如果您想要独立副本,请使用
bzr get
,如果您想自动绑定到原始分支:使用bzr 结帐
。如果您稍后改变主意并希望它的行为更像 SVN,您可以执行 bzr 绑定,您所做的任何提交都将自动提交到父分支。
Basically you have the option of not being tied to the branch you got the code from: if you want a standalone copy use
bzr get
, if you want to be automatically bound to the original branch: usebzr checkout
.If you change your mind later and want it to behave more like SVN, you can do a
bzr bind
and any commits you make will automatically be committed to the parent branch.