[merge][#249908] avoid bad text wrapping when generating documentation

Martin Pool mbp at canonical.com
Tue Jun 16 05:43:53 BST 2009


2009/3/25 John Arbash Meinel <john at arbash-meinel.com>:
>> Well, it was a lazy change to cope with that script now being inside
>> the tools directory, relative to where setup.py runs.  Maybe we should
>> modify sys.path instead?
>>
>
> import tools.generate_docs
> tools.generate_docs(...)
>
> or
>
> from tools import generate_docs
> generate_docs(...)
>
> You just have to access it by the variable you imported it as. Sorry I
> was a bit terse originally.

I came back to this patch because my attempt to merge it with your
suggestions was rejected by pqm.  I found what seem to be some cases
where it'll generate docs from the system's bzrlib rather than the one
in the tree, which would be subtly wrong.  (This could happen if you
run ./tools/doc_generate.py, without explicitly putting the base of
the source tree on the pythonpath.)

Thinking about this it seemed better to just put doc_generate inside
bzrlib.  It's something we could potentially avoid installing later,
but I think it is included in the package at the moment anyhow.
Shipping it seems potentially useful anyhow if for example a GUI
wanted to display up-to-date help from the library.

-- 
Martin <http://launchpad.net/~mbp/>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 20090616-249908-doc-generate.diff
Type: text/x-patch
Size: 25329 bytes
Desc: not available
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20090616/55cdba2c/attachment-0001.bin 


More information about the bazaar mailing list