When manually resolving directory conflicts isn't a feature
John Arbash Meinel
john at arbash-meinel.com
Mon Apr 6 14:59:04 BST 2009
-----BEGIN PGP SIGNED MESSAGE-----
Nagy Viktor wrote:
> I don't use bzr switch and the likes, but I use bzr with LaTeX as well.
> Does adding your unversioned files to bzr ignore solve the problem? (I
> don't know how bzr handles this "not delete non versioned files"
> situation, but if you require it to ignore files, it might manage to
> really ignore them.)
So unfortunately we made a specific choice, and we need to figure out
how to resolve it.
Specifically, when you 'bzr switch', we will try to remove a directory
that doesn't exist in the target.
Any unversioned file (ignored or unknown) in a directory will prevent us
from deleting it, and give a directory conflict. (We couldn't remove a
directory because it wasn't empty.) We would do the same thing for a
file that had been modified but not committed, but did not exist in the
However, the directory case is probably a bit more confusing and a bit
harder to resolve. (At least with 'bzr resolve' it can auto-resolve a
file with conflicts, or switch can merge the uncommitted changes, etc.)
We've talked about adding a "junk" filter. Which would list filenames
that are fine to just delete without warning. (Stuff like .pyc, .o,
.swp, and all the LaTeX droppings.)
It would add some UI complexity, because now a file has yet another state:
Unknown Not mentioned anywhere, not versioned
Ignored Listed in .bzrignore and not versioned
Junk Listed in XXX and not versioned, may be deleted by bzr
Versioned Tracked, and supersedes all other classifications
The difficulty is stuff like "do you add a .bzrjunk", "do you make it an
extra field in .bzrignore", etc.
If the only reason to add it is because of directories that we cannot
delete because they have unknown/ignored files in them, maybe we just
want to leave the directory there, but unversion it and not mark it as a
conflict. Or perhaps only do that if there are only ignored (but no
The problem with 'ignored' is that 99% of the time it means junk that I
don't want to version. But *sometimes* it means "this is a mission
critical config file, which I have to have to keep things working, but
it has secrets (passwords) that I cannot version".
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
-----END PGP SIGNATURE-----
More information about the bazaar