[racket] Literate Programming and Scribble

From: Neil Van Dyke (neil at neilvandyke.org)
Date: Thu Sep 9 23:59:58 EDT 2010

Eli Barzilay wrote at 09/09/2010 11:31 PM:
> On Sep  9, Neil Van Dyke wrote:
>> If the math source format is in TeX syntax (which most people would say it should be), I'd think that you could avoid computing the secure hash, and just use an escaped variation of the TeX syntax string as the filename.
>> Escaped strings longer than the max filename length for the underlying filesystem (255 chars for ext2) can be split into subdirectories,
> But these kinds of limits are easy to exceed.  (Not to mention that you need to think about the host of other tools that might have problems -- like tarring up a directory, serving it through http, etc.)

You could do short TeX strings (say, up to around 200 characters) as 
(escaped) filenames.  In the less-frequent case that the TeX strings are 
larger, the strings get SHA-1'd for the filename and perhaps go into a 
different parent directory.

But if you don't mind SHA-1-ing for every case (i.e., computer 
sufficiently fast or memoize), that does have the simplicity advantage 
of avoiding the branch.

I'll sign off on either way. :)

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/users/archive/attachments/20100909/b36e91d0/attachment.html>

Posted on the users mailing list.