Using bzr with LaTeX
José Orlando Pereira
jop at lsd.di.uminho.pt
Fri Dec 15 12:17:59 GMT 2006
On Wednesday 13 December 2006 11:35 pm, John Arbash Meinel wrote:
> t u wrote:
> > Hi,
> >
> > I am brand new to both LaTeX and bzr and it's kinda hard to learn both
> > at the same time.
> >
> > I was wondering whether you have any pointers for tips and tricks on
> > using bzr along with LaTeX for people who write articles (instead of
> > code).
>
> The biggest thing that I've run run into when using bzr + LaTeX is that
> you want to try to break your paragraphs up a little bit more than you
> might otherwise.
>
> Really this is the case for any form of textual documentation. Word
> wrapping and diff algorithms don't get along very well together. This
> really doesn't have anything specifically to do with bzr, it is just a
> general thing about versioning documentation.
>
Hi,
A long time ago, while learning Python, I tried to solve this by writing a
script to normalize TeX source, i.e. reflowing to 1 sentence == 1 line. Diffs
(and tools such as kompare or kdiff3) are then much more user friendly. I
would then de-normalize to edit, i.e. 70 char lines/no line break on
sentences.
The small python script to do this is attached. By running it with no
parameters, it normalizes stdin to stdout. By running it with a parameter, it
uses it as the maximum line length to de-normalize.
It tries to be clever and reflow only pure text lines in order no to mess
xy-pic, tabulars, etc. But... <WARNING>I never used this regularly, so be
very careful!</WARNING>. A simple shell script showing how to use it with
kompare is attached also. Kompare is nice as it shows what has changed within
the line.
Have fun, ;)
--
Jose Orlando Pereira
-------------- next part --------------
A non-text attachment was scrubbed...
Name: texkompare
Type: application/x-shellscript
Size: 105 bytes
Desc: not available
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20061215/65e425b2/attachment.bin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: texnorm.py
Type: application/x-python
Size: 1538 bytes
Desc: not available
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20061215/65e425b2/attachment-0001.bin
More information about the bazaar
mailing list