bzr cp? and bzr cp -r

James Westby jw+debian at jameswestby.net
Mon Aug 13 17:37:43 BST 2007


On (11/08/07 08:17), Hendy Irawan wrote:
> Is there such thing as bzr cp?
>
> I'm "moving" (actually, adding Bazaar as compliment) from Subversion and 
> I'm wondering how to do svn cp , the bzr way?
>
> Do I just regular cp using shell? If so, how would bzr know the history 
> related to the cp?

Bazaar does not currently support recording file copies. Currently only
one copy can be linked to the history, the other must be added as a new
file.

It is a feature that is hoped for in the future.

>
> And a second issue is, how do I cp from a specific revision? In Subversion 
> if I want to copy a file from a previous revision (reverting back, for 
> instance, or manually "merging" a file from another branch) I just use svn 
> cp --revision X. I wonder how to do this in Bazaar.

To revert a file to a previous version then you can use revert. However
to do a copy to a new file from a previous version of another I would
use cat.

  bzr cat -r -5 file > copy-of-file

but again this does not record the file copy and "copy-of-file" would
have to be added as a new file.

Thanks,

James

-- 
  James Westby   --    GPG Key ID: B577FE13    --     http://jameswestby.net/
  seccure key - (3+)k7|M*edCX/.A:n*N!>|&7U.L#9E)Tu)T0>AM - secp256r1/nistp256



More information about the bazaar mailing list