Skip to content

Xml2Prfc

sethnielson edited this page Feb 28, 2019 · 1 revision

You will find a tcl utility in the repository under src/prfc/xml2prfc.tcl. This script takes an xml file as input and produces either a txt or html output. The usage is very simple:

xml2prfc.tcl <xmlfile>.xml <txtfile>.txt

or

xml2prfc.tcl <xmlfile>.xml <htmlfile>.html

You will need to install tcl in order to run this script. For Ubuntu linux, you should be able to apt install tcl. I think that is everything you need to make this work.

The utility is very helpful but it's also fragile. The error messages are cryptic. I have included prfc 1 as a sample. I highly recommend that you test this first:

xml2prfc.tcl p_rfc_1.xml p_rfc_1.txt

When you start writing your own PRFC, start with an "empty" prfc and make sure you get output. Then, slowly add sections, ensuring that each section still results in a legitimate output. When you come across a strange error, at least you know it's in a recently added section and you can try to diagnose it.

Share what you learn about errors and outputs on campuswire.