<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
  <title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
Eli Barzilay wrote at 09/09/2010 11:31 PM:
<blockquote cite="mid:19593.42663.864611.478185@winooski.ccs.neu.edu"
 type="cite">
  <pre wrap="">On Sep  9, Neil Van Dyke wrote:
  </pre>
  <blockquote type="cite">
    <pre wrap="">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,
    </pre>
  </blockquote>
  <pre wrap=""><!---->
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.)
  </pre>
</blockquote>
<br>
You could do short TeX strings (say, up to around 200 characters) as
(escaped) filenames.&nbsp; 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.<br>
<br>
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.<br>
<br>
I'll sign off on either way. :)<br>
<br>
<div class="moz-signature">-- <br>
<a class="moz-txt-link-freetext" href="http://www.neilvandyke.org/">http://www.neilvandyke.org/</a>
</div>
</body>
</html>