Modify

Ticket #411 (closed defect: fixed)

Opened 15 years ago

Last modified 15 years ago

Printable Documentation

Reported by: dclark Owned by: desai
Priority: minor Milestone: Bcfg2 0.9.5 Release
Component: bcfg2-doc Version: 0.9.x
Keywords: doc, documentation Cc:

Description

Now that the doc is moving from XML files to the Wiki, there needs to be some way of printing out the Wiki documentation, as there is 50+ pages of docs, and reading large docs on surfaces other than paper can be annoying.

The easiest solution I have found involves 2 Trac plugins and HTMLDOC:

  1. apt-get install htmldoc
  2. Install the WikiIncludePlugin
  3. Install the PageToPdfPlugin, after patching it it to allow a TOC to be generated with the patch in this ticket
  4. Modify the trac.ini with the [pagetopdf] options in the above ticket, as well as with these lines in the [components] section:
    pagetopdf.* = enabled
    wikiinclude.* = enabled
    
  5. /etc/init.d/apache2 reload

I like doing (2) and (3) like this to maintain easy compatibility with bcfg2:

  1. fakeroot python setup.py bdist_rpm
  2. cd dist; fakeroot alien -d *noarch*rpm
  3. install .deb via bcfg2

This solution will get you something that looks like this. The one downside of this is that there will not be a title page - that should be relatively easy to patch PageToPdfPlugin to do; the code to get the title info from Trac itself is already in the CombineWikiPlugin. I have an example of bcfg2 doc created with this; it was running from another trac wiki, and so pulled in the crap that frames the content text; that would not be the case within a wiki using the include plugin.

Attachments

Change History

comment:1 Changed 15 years ago by bradshaw

I just enabled those 2 plugins for the bcfg2 trac site. Please test them out to ensure they are working properly. The test I had fail in the past just worked, but it isn't complicated.

Rick

comment:2 Changed 15 years ago by desai

  • Status changed from new to closed
  • Resolution set to fixed

comment:3 Changed 15 years ago by dclark

  • Status changed from closed to reopened
  • Resolution fixed deleted

(From IRC 2007-05-01)

  • So concatenated doc is now up at http://trac.mcs.anl.gov/projects/bcfg2/wiki/Bcfg2Doc ; there are some obvious problems (see pink boxes), and also the PDF creation doesn't look like it is working (may just be my comp, will try from another soon)
  • Also need to figure out how to strip the [[TracNav]] elements.
  • Specifically the problems are:
    1. Strip [[TracNav]]
    2. Change WikiInclude to properly deal with image attachments (i.e. rewrite to refer to origin page, not page from which it is included)
    3. Add [[TOC]] macro to Trac instance
    4. Fix PDF creation

comment:4 Changed 15 years ago by dclark

It looks like "4. Fix PDF creation" has been fixed, and items 1-3 still need to be worked on.

comment:5 Changed 15 years ago by dclark

  • Component changed from bcfg2-client to bcfg2-doc

comment:6 Changed 15 years ago by desai

  • Status changed from reopened to closed
  • Resolution set to fixed

I think this is working now.

WARNING! You need to establish a session before you can create or edit tickets. Otherwise the ticket will get treated as spam.

View

Add a comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
The resolution will be deleted. Next status will be 'reopened'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.