bzr unexpectedly changes backslash to forward slash in 'bzr ignore' arguments

Bug #936587 reported by Alexander Belchenko
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Bazaar
Confirmed
Medium
Unassigned

Bug Description

I found this problem while I was working on qignore dialog for QBzr. I have problems to pass some ignore patterns, like RE:\.?[^.]+
down to bzr's ignore command. I'm able to reproduce the problem with bzr itself.

C:\Temp>bzr init 1
Created a standalone tree (format: 2a)

C:\Temp>cd 1
C:\Temp\1>

C:\Temp\1>bzr ignore RE:\.?[^.]+

C:\Temp\1>type .bzrignore
RE:/.?[.]+

I suspect this could be windows-specific problem and related to custom command line splitter code.

Revision history for this message
Alexander Belchenko (bialix) wrote :

bzr.exe 2.4.2 @ windows xp

description: updated
Revision history for this message
Alexander Belchenko (bialix) wrote :

The only one way to prevent this bad behavior is to quote the argument:

C:\Temp\1>bzr ignore "RE:\.?[^.]+"
Warning: the following files are version controlled and match your ignore pattern:
.bzrignore
These files will continue to be version controlled unless you 'bzr remove' them.

C:\Temp\1>type .bzrignore
RE:\.?[^.]+

But the problem for QBzr is that it won't quote such argument, unless there is spaces inside.

I'd like to understand why bzr behaves so strange.

Vincent Ladeuil (vila)
Changed in bzr:
status: New → Confirmed
importance: Undecided → Medium
summary: - bzr unexpectedly changes backslash to forward slash in arguments
+ bzr unexpectedly changes backslash to forward slash in 'bzr ignore'
+ arguments
Jelmer Vernooij (jelmer)
tags: added: check-for-breezy
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.