bzr: ERROR: Target directory "." already exists. (bzr branch into current dir)

Bug #686262 reported by Paul Sladen
16
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Bazaar
Confirmed
Undecided
Unassigned
Breezy
Triaged
Medium
Unassigned

Bug Description

Asking bzr to branch into the current directory produces:

  $ bzr branch lp:somewhere/something .
  bzr: ERROR: Target directory "." already exists.

This seems to be a case of bzr trying to be too clever and I think the complaint should perhaps only be shown if $target/.bzr/ already exists, rather than just $target/ itself. If I read bug #120511 correctly, this may have originally tried to be fixed.

Tags: easy ui
Paul Sladen (sladen)
summary: - bzr: ERROR: Target directory "." already exists. (bzr branch somewhere
- .)
+ bzr: ERROR: Target directory "." already exists. (bzr branch into
+ current dir)
description: updated
Revision history for this message
Andrew Bennetts (spiv) wrote :

There's already the --use-existing-dir option to provide this behaviour.

So the issues I see are:

 1. is the current behaviour a good default? (My feeling is yes.)
 2. the error message doesn't suggest --use-existing-dir, but probably should.

Revision history for this message
Paul Sladen (sladen) wrote :

Having the error message explictly mention that '--use-existing-dir' will override the check would be good enough for me.

(Interestingly, I had presumed that --use-existing-dir was only relevant when pushing remotely, and it did not occur to me that it would be usable locally. It's use did not occur to me, even knowing about it).

Vincent Ladeuil (vila)
Changed in bzr:
status: New → Confirmed
tags: added: easy ui
Jelmer Vernooij (jelmer)
tags: added: check-for-breezy
Jelmer Vernooij (jelmer)
tags: removed: check-for-breezy
Jelmer Vernooij (jelmer)
Changed in brz:
status: New → Triaged
importance: Undecided → Medium
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.