Bazaar: Moving files after the fact

I recently came across a useful flag that can be use with Bazaar's move command. --after can be used to update bazaar's internal reference to the file after you've already moved the file.

The syntax is as follows:

$ mv  foo bar # Doh should have used bzr mv
$ bzr mv --after foo bar
renamed foo => bar

Moving files without telling bazaar will just simply remove them from their original location and require you to re-add them. The point of using bzr mv is that it tracks renames. The has a huge benefit when merging as Bazaar knows that the file that was formerly "foo" is now called "bar". Any changes to "foo" will be correctly applied to "bar".

Show Comments