why does bazaar not add a file automatically on the first commit

Martin Pool mbp at canonical.com
Wed Apr 23 01:33:36 BST 2008


On Wed, Apr 23, 2008 at 7:51 AM, Wichmann, Mats D
<mats.d.wichmann at intel.com> wrote:
>  I personally agree it makes sense to add files when specified
>  by name, and perhaps directory (+contents) when specified by name.
>  But not otherwise. For example, if I just say "bzr commit" inside
>  a branch, it should not make assumptions. I've just recovered from
>  a mistake I made where several files were auto-removed because
>  they weren't present in a directory when I committed a change.
>  There were no warnings; I'd rather have an error in this situation
>  and have to do something explicit to commit anyway.  As it is,
>  it requires me to do extra work to confirm that something isn't
>  going to happen by mistake. In fact, I'll take this moment to
>  declare that this is a Horrible Mistfeature, Please Put It Back
>  The Way It Was!!!!  It completely violates the principle of
>  "No Surprises".

We've always automatically removed missing files from commit.  I
believe we've agreed that it would be more consistent not to do this
automatically unless an option is given.  It makes sense to add this
at the same time as auto-add.

But unless I'm misunderstanding you, you should not have lost any work
this way - just an uncommit and revert on those files will get them
back.

-- 
Martin <http://launchpad.net/~mbp/>



More information about the bazaar mailing list