[racket] Getting started with Scribble

From: Mark Engelberg (mark.engelberg at gmail.com)
Date: Fri Mar 16 22:45:35 EDT 2012

I'm sort of thinking along the lines of Haskell's version of literate
programming, where if you use the file suffix of lhs instead of hs, rather
than having a file that is mostly code with occasional comments, you can
easily write a document that is mostly text with occasional code.  In that
mode, by default, a line is treated as text unless it has a > at the
beginning of the line to indicate it is code.

I was under the impression that with Scribble, I could do something similar
(mostly text, but with occasional code blocks), but would have the
additional benefits of Scribble's mark-up capabilities.  I see now that
that's not precisely how Scribble is intended to be used.

I'm interested because I've asked a student to turn a program into a highly
readable document, and I want to give her some simple options.  I thought
this would be the perfect way to have a runnable program, but also be able
to generate a great-looking html page.

scribble/lp is related, but more involved to use.  Specifically, I just
tried it and it doesn't seem to work with the scribble html button that
appears in DrRacket.  I keep getting the following error:
scribble: loading xref
scribble: rendering
reference to an identifier before its definition: doc

Maybe it only works via lp-include?

On Fri, Mar 16, 2012 at 7:32 PM, Robby Findler
<robby at eecs.northwestern.edu>wrote:

> What you're asking for is not what Scribble does, mostly speaking.
> Running a scribble program just builds a datastructure for the
> rendering process.
>
> You might try the scribble/lp library, tho. I think that comes closest.
>
> Robby
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/users/archive/attachments/20120316/d1f07538/attachment-0001.html>

Posted on the users mailing list.