Manpage of nwsc
Section: ARSD Tools (1)
Updated: 27 August 2006
Return to Main Contents
nwsc - the new simple web site compiler
input file, output file
is a simple program that takes an HTML input file with a small set of macros, and expands those macros, forming a finished HTML page.
The file should be a valid XHTML chunk with macros added in the form of <#macro_name "argument" ...>.
It may also have HTML <h?> tags to show information headers.
automatically adds <a name> tags to headers and may generate a table of contents for them
The program supports a small number of macros to aid in making the web page.
Currently, the only way to add new macros is by modifying the source code (see function dosomething() on line 183 in nwsc.c if you want to give it a try).
Outputs a ul navmenu formed by recursively scanning the source directory (hardcoded) for directories and html files, ignoring dot files.
Includes the file given in the first argument in this file, passing any subsequent arguments to that file.
<#include ``file'' ``argument''>
Generates a table of contents for the following data and inputs it in the output data.
It looks for <h1>, <h2>, etc tags in the HTML to know where contents begin.
If this appears inside a <h?> tag, it will only generate contents sub headers of this tag.
Outputs the date when the file was compiled.
Outputs a back to top link.
Outputs the contents of the argument passed to this file if it was
Argument 0 is the filename, arguments 1 and beyond are given on the include macro.
Outputs the footnotes. This may only occur once in a stream.
Adds a footnote with the first argument as the footnote text.
This text may be any inline HTML, including links.
macro to output the notes somewhere in your file.
If you need to use a quote in the note text, remember to escape it with a backslash (like in C).
<#fn ``note text''>
Copyright (C) 2006, Adam D. Ruppe, released under the GNU General Public License.
It doesn't really handle errors; it either just keeps going silently or fails silently.
It doesn't understand HTML comments, so it is not possible to simply comment out code in your source file.
Adam D. Ruppe ( firstname.lastname@example.org )
27 August 2006 - First release
- SEE ALSO
This document was created by
using the manual pages.
Time: 03:33:54 GMT, October 04, 2007