[ANN] EOL conversion support now in bzr.dev

Brian de Alwis bsd at cs.ubc.ca
Sat Apr 4 23:11:32 BST 2009


Hi Ian.  I submitted bug #355280 earlier this morning about the eol  
support.  In trying to debug this further, I've discovered that my  
actual problem is that the eol filters aren't being loaded at all. (I  
would update the bugreport, but launchpad is down.)

I've created a rules file with an eol clause. If I start with pdb and  
explicitly import bzrlib.filters.eol, then the eol filters are loaded  
and applied.  Without this, bzrlib/filters/eol.py is never loaded and  
the filters are never applied.

I've scoured the documentation, but I don't see what I've missed.

In more detail.

1.  I've creates a rules file in ~/.bazaar/rules that contains:

[name *.cs]
eol = crlf

2. I configured my branch to have no working tree.

$ bzr114 remove-tree

3. I try cat of a file:

$ /scratch/dev/bzr-1.14/bzr -Dfilters cat --filters j.cs | hexdump -C

The file doesn't have CRLFs.

I eventually put print statements at the top of bzrlib/rules.py,  
bzrlib/filters/__init__.py and bzrlib/filters/eol.py so I could see if  
they're loaded.

$ /scratch/dev/bzr-1.14/bzr cat --filters j.cs
==> filters/__init__.py
==> rules.py
THis is a test
Foo

I then modified rules.py to explicit import bzrlib.filters.eol, and I  
then see the filters applied, with CRLFs.

Am I doing something wrong?  Is there some setting required somewhere  
that I'm missing?

Thanks.

Brian.

-- 
"Amusement to an observing mind is study." - Benjamin Disraeli




More information about the bazaar mailing list