build index.html for all winners

Updated manifest as per recent file changes.

Updated winner `.winner.json` to reflect the manifest changes.

Added [bin/all_run.sh](bin/all_run.sh) tool to run a command over
all winning entries.

These tools had slight improvements in the help usage message:

* bin/gen-author.sh VERSION="1.3.1 2024-01-16"
* bin/gen-inventory.sh VERSION="1.0.1 2024-01-16"
* bin/pandoc_wrapper.sh VERSION="1.3.1 2024-01-16"
* bin/subst.default.sh VERSION="1.1.1 2024-01-16"
* bin/subst.winner-index.sh VERSION="1.1.1 2024-01-16"

The `bin/readme2index.sh` tool was improved so that
if the `index.html` file exists and the tool forms
the exact same content, then the file `index.html`
file is NOT touched.

* bin/readme2index.sh VERSION="1.1 2024-01-16"

We used the following command to generate `index.html` files
for all winning entries:

```sh
bin/all_run.sh -v 3 bin/readme2index.sh
```

NOTE: We have not (yet) built HTML files above the winner directory
level (e.g., no year level nor top level HTML), nor have be built
non-index HTML files for winners.

NOTE: By default we are running `pandoc(1)` with:

```
--fail-if-warnings=true
```

This means that any problems with markdown to HTML
generates an error.  This is done to be sure that
the HTML conversion is clean.

We had to fix the following `README.md` files:

* `2000/rince/README.md`

The reference [^2] was never used.  We made a guess that [^2] applies
to the same spot as [^1].  Perhaps there is a better spot where
[^2] applies?

NOTE: For every reference, there MUST be some place where that
reference is used.

* 2012/vik/README.md

The string "$...$" is assumed to be a TeX encoded string.

NOTE: Every "$..$" needs to be backslashed as in "\$..\$".

* 2018/burton1/README.md

The reference [2] was duplicated.  We changed the
second [2] to [3].

NOTE: Every reference needs to have a unique number.

* 2020/carlini/README.md

The string "$...$" is assumed to be a TeX encoded string.

NOTE: Every "$..$" needs to be backslashed as in "\$..\$".

We also found 2 errors in the `author/author_handle.json` file set:

* author/Anonymous_2001.json

The `author/Anonymous_2001.json` file was missing.

* author/Jari_Arkko.json

The winner ID for `1989_jar.1` had a typo.
This commit is contained in:
Landon Curt Noll committed 2024-01-17 00:32:39 -08:00
1 parent 893cd915b6
commit c1466f5165
350 files changed
+95242 -4217

No files matched your search

+366 -13
View File
@@ -1,4 +1,6 @@
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<!-- START: two lines up starts content from: inc/top.default.html -->
<!-- -->
<!-- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
<!-- !!! DO NOT MODIFY THIS FILE - This file is generated by a tool !!! -->
@@ -6,27 +8,378 @@
<!-- !!! DO NOT MODIFY THIS FILE - This file is generated by a tool !!! -->
<!-- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
<!-- -->
<!-- file: 1992/adrian/index.html created by: fake.gen_index.sh version: 1.0.5 2023-10-31 -->
<html lang="en">
<!-- END: this line ends content from: inc/top.default.html -->
<!-- -->
<!-- This file was formed by the tool: bin/readme2index.sh version: 1.1 2024-01-16 -->
<!-- -->
<!-- START: this line starts content from: inc/head.default.html -->
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>1992 adrian</title>
<meta name="description" content="IOCCC year: 1992 IOCCC winner: adrian winner index page">
<meta name="keywords" content="IOCCC,1992,adrian,winner index page">
<link rel="stylesheet" href="/temp-test-ioccc/ioccc.css">
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes">
<title>1992/adrian</title>
<meta name="description" content="1992 IOCCC winner adrian">
<meta name="keywords" content="IOCCC, 1992, IOCCC 1992, IOCCC winner, adrian">
</head>
<!-- END: this line ends content from: inc/head.default.html -->
<!-- START: this line starts content from: inc/body.default.html -->
<body>
<h1>1992 adrian</h1>
<!-- END: this line ends content from: inc/body.default.html -->
<!-- START: this line starts content from: inc/header.default.html -->
<p>XXX - fake content until readme2index is working - XXX</p>
<div class="header">
<img src="/temp-test-ioccc/png/ioccc.png" alt="IOCCC image by Matt Zucker" width=300 height=110>
<h1>The International Obfuscated C Code Contest</h1>
<h2>1992/adrian</h2>
</div>
<hr style="width:50%;text-align:left;margin-left:0">
<!-- END: this line ends content from: inc/header.default.html -->
<!-- START: this line starts content from: inc/topnav.first.html -->
<!-- Start Nu Html Checker -->
<p><a href="https://validator.w3.org/nu/?doc=https%3A%2F%2Fioccc-src.github.io%2Ftemp-test-ioccc%2F1992%2Fadrian%2Findex.html">Nu Html check https://ioccc-src.github.io/temp-test-ioccc/1992/adrian/index.html</a></p>
<!-- End Nu Html Checker -->
<div class="topnav">
<a class="Left Disabled" href="#">first entry</a>
<a class="Left" href="../index.html">&uarr; 1992 &uarr;</a>
<a class="Left" href="../albert/index.html">albert &rarr;</a>
<a class="Right" href="#inventory">Inventory</a>
</div>
<!-- END: this line ends content from: inc/topnav.first.html -->
<!-- START: this line starts content from: inc/begin-row.default.html -->
<div class="row">
<!-- END: this line ends content from: inc/begin-row.default.html -->
<!-- START: this line starts content from: inc/begin-leftcolumn.default.html -->
<div class="leftcolumn">
<!-- END: this line ends content from: inc/begin-leftcolumn.default.html -->
<!-- START: this line starts content from: inc/sidenav.default.html -->
<div class="sidenav">
<a href="#content">Jump to contents</a>
</div>
<hr>
<div class="sidenav">
<a href="/temp-test-ioccc/index.html">IOCCC Home</a>
<a href="/temp-test-ioccc/years.html">Winning Entries</a>
<a href="/temp-test-ioccc/winners.html">People who have won</a>
</div>
<hr>
<div class="sidenav">
<a href="/temp-test-ioccc/news.html">IOCCC News</a>
<a href="/temp-test-ioccc/faq.html#submit">How to enter the IOCCC</a>
<a href="/temp-test-ioccc/faq.html">FAQ</a>
</div>
<hr>
<div class="sidenav">
<a href="/temp-test-ioccc/bugs.html">Bugs &amp; (mis)features</a>
<a href="/temp-test-ioccc/faq.html#fix_a_winner">Fixing IOCCC winners</a>
<a href="/temp-test-ioccc/faq.html#fix_web_site">Fixing the web site</a>
<a href="/temp-test-ioccc/faq.html#fix_author">Fixing winner info</a>
<a href="/temp-test-ioccc/thanks-for-help.html">Thanks for the help</a>
</div>
<hr>
<div class="sidenav">
<a href="/temp-test-ioccc/judges.html">The IOCCC Judges</a>
<a href="/temp-test-ioccc/contact.html">Contacting the IOCCC</a>
</div>
<hr>
<div class="sidenav">
<a href="#top">Jump to top</a>
</div>
<!-- END: this line ends content from: inc/sidenav.default.html -->
<!-- START: this line starts content from: inc/end-leftcolumn.default.html -->
</div>
<!-- END: this line ends content from: inc/end-leftcolumn.default.html -->
<!-- START: this line starts content from: inc/begin-rightcolumn.default.html -->
<div class="rightcolumn">
<!-- END: this line ends content from: inc/begin-rightcolumn.default.html -->
<!-- START: this line starts content from: inc/before-content.default.html -->
<a name="content"></a>
<!-- END: this line ends content from: inc/before-content.default.html -->
<!-- START: this line starts content generated by: bin/gen-author.sh -->
<p><a name="author"><strong>Author:</strong></a> <br><br>Name: <a
href="/temp-test-ioccc/winners.html#Adrian_Mariano">Adrian
Mariano</a><br> Location: <a
href="/temp-test-ioccc/location.html#US">US</a></p>
<!-- END: next line ends content generated by: bin/gen-author.sh -->
<h2 id="to-build">To build:</h2>
<div class="sourceCode" id="cb1"><pre class="sourceCode sh"><code class="sourceCode bash"><span id="cb1-1"><a href="#cb1-1" aria-hidden="true" tabindex="-1"></a><span class="fu">make</span> all</span></code></pre></div>
<h3 id="bugs-and-misfeatures">Bugs and (Mis)features:</h3>
<p>The current status of this entry is:</p>
<pre><code>STATUS: known bug - please help us fix
STATUS: INABIAF - please **DO NOT** fix</code></pre>
<p>For more detailed information see <a href="/bugs.md#1992-adrian">1992
adrian in bugs.md</a>.</p>
<h2 id="try">Try:</h2>
<div class="sourceCode" id="cb3"><pre class="sourceCode sh"><code class="sourceCode bash"><span id="cb3-1"><a href="#cb3-1" aria-hidden="true" tabindex="-1"></a><span class="ex">./try.sh</span></span></code></pre></div>
<p>For the slow minded, try:</p>
<div class="sourceCode" id="cb4"><pre class="sourceCode sh"><code class="sourceCode bash"><span id="cb4-1"><a href="#cb4-1" aria-hidden="true" tabindex="-1"></a><span class="ex">./adsleep</span> 32767</span></code></pre></div>
<h2 id="judges-remarks">Judges’ remarks:</h2>
<p>Once you get past the obfuscation, you have an opportunity to learn
about regular expressions and state machines.</p>
<p>NOTE: Some compilers have had trouble optimizing this entry.</p>
<h2 id="authors-remarks">Author’s remarks:</h2>
<h3 id="adrians-grep-adgrep">ADrian’s GREP (adgrep)</h3>
<p>For those confused by the complexity of full-blown
<code>egrep(1)</code> style regular expressions, this program offers an
alternative. It implements an equivalent search, using a deterministic
finite automaton.</p>
<p>A deterministic finite automaton consists of a finite set of states,
along with transition rules to move from one state to another, an
initial state, and a set of accepting states. The automaton takes a
string as input and begins in the start state. It reads a character of
the string and consults the rules for the current state, moving to the
new state indicated by the appropriate rule. This process is repeated
until the string is consumed. If the current state at this point is one
of the accepting states, then the string is accepted.</p>
<p>The deterministic finite automaton is specified as a series of rules
for each state:</p>
<pre><code>&lt;state&gt; chars1 &lt;dest1&gt; chars2 &lt;dest2&gt; ...</code></pre>
<p><code>chars1</code> is a list of characters (<em>only the first
8</em> are significant) which should trigger a transition to
<code>&lt;dest1&gt;</code>. <code>&lt;dest1&gt;</code> is another state
which should have a similar specification somewhere. A state is
accepting if it is specified in square brackets: <code>[final]</code>;
state strings are significant to only eight characters like
<code>chars1</code>.</p>
<h3 id="example-1-matches-abc">Example 1: matches
<code>^abc$</code></h3>
<pre><code>&lt;q0&gt; a &lt;q1&gt; The first state to appear is the start state
&lt;q1&gt; b &lt;q2&gt;
&lt;q2&gt; c [q3]
[q3]</code></pre>
<p>Technically, a deterministic finite automaton should have a rule for
each possible input character at each state. To simplify descriptions of
the automata, if no rule is present, the string will not be accepted.
Also, the <code>.</code> character matches any character if it occurs
first in the character list.</p>
<h3 id="example-2-abc">Example 2: <code>^abc</code></h3>
<pre><code>&lt;q0&gt; a &lt;q1&gt;
&lt;q1&gt; b &lt;q2&gt;
&lt;q2&gt; c [q3]
[q3] . [q3]</code></pre>
<h3 id="example-3-abc">Example 3: <code>abc$</code></h3>
<pre><code>&lt;q0&gt; a &lt;q1&gt; . &lt;q0&gt;
&lt;q1&gt; b &lt;q2&gt; a &lt;q1&gt; . &lt;q0&gt;
&lt;q2&gt; c [q3] a &lt;q1&gt; . &lt;q0&gt;
[q3] . &lt;q1&gt;</code></pre>
<h3 id="example-4-abc">Example 4: <code>^(abc)*$</code></h3>
<pre><code>[q0] a &lt;q1&gt;
&lt;q1&gt; b &lt;q2&gt;
&lt;q2&gt; c [q0]</code></pre>
<h3 id="example-5-abcdef">Example 5: <code>^[ab][cd][ef]$</code></h3>
<pre><code>&lt;q0&gt; ab &lt;q1&gt;
&lt;q1&gt; cd &lt;q2&gt;
&lt;q2&gt; ef [q3]
[q3]</code></pre>
<h3 id="example-6-abcefg">Example 6: <code>^(abc|efg)$</code></h3>
<pre><code>&lt;q0&gt; a &lt;q1&gt; e &lt;q3&gt;
&lt;q1&gt; b &lt;q2&gt;
&lt;q2&gt; c [q5]
&lt;q3&gt; f &lt;q4&gt;
&lt;q4&gt; g [q5]
[q5]</code></pre>
<p>With the automaton specification in <code>filename</code>, invoke the
program by typing</p>
<div class="sourceCode" id="cb12"><pre
class="sourceCode sh"><code class="sourceCode bash"><span id="cb12-1"><a href="#cb12-1" aria-hidden="true" tabindex="-1"></a><span class="ex">./adrian</span> filename</span></code></pre></div>
<p>It will read the file and print out all the lines which the automaton
accepts. If the file cannot be opened, a system error message will be
printed. If the input contains errors, then an error message along with
the number of the offending line will be printed to stderr. The number
of rules for each state is limited to 17. If more than 17 rules are
present, you get the error <code>too_many_rules</code>, and the state
that was being processed is printed. Error <code>no_destination</code>
occurs if you specify a set of characters, but no destination state, and
error <code>too_many_states</code> occurs if your automaton has more
than 257 states.</p>
<p>Running:</p>
<div class="sourceCode" id="cb13"><pre
class="sourceCode sh"><code class="sourceCode bash"><span id="cb13-1"><a href="#cb13-1" aria-hidden="true" tabindex="-1"></a><span class="ex">./adrian</span> from <span class="op">&lt;</span> your_mailbox</span></code></pre></div>
<p>will perform a function similar to that of the unix <code>from</code>
command.</p>
<p>If no filename is specified on the command line, then
<code>__FILE__</code> is used as the specification for the automaton.
(Originally this was <code>"adgrep.c"</code> but the file was renamed to
<code>adrian.c</code> by the judges and for more portability the arg was
changed to <code>__FILE__</code>.) In this case, the program will search
for matches to the regular expression:</p>
<pre><code>^.[^|C][^w[Q]*(Q|[w[]c).*|^.[C|]$</code></pre>
<p>I suggest using <code>adrian.c</code> as input, and storing the
output in <code>adwc.c</code>:</p>
<div class="sourceCode" id="cb15"><pre
class="sourceCode sh"><code class="sourceCode bash"><span id="cb15-1"><a href="#cb15-1" aria-hidden="true" tabindex="-1"></a><span class="ex">./adrian</span> <span class="op">&lt;</span> adrian.c <span class="op">&gt;</span> adwc.c</span></code></pre></div>
<p>Compiling the new file, <code>adwc.c</code>, yields a clone of the
unix <code>wc</code> command. It runs on one file, defaulting to
<code>"adrian.c"</code> if no file is given (again, this was changed to
be <code>__FILE__</code>) and displays the number of lines, words, and
bytes in the input file.</p>
<p>Another possibly interesting automaton can be created by slightly
adjusting the <code>adrian.c</code> file. Change the first line to
read</p>
<div class="sourceCode" id="cb16"><pre class="sourceCode c"><code class="sourceCode c"><span id="cb16-1"><a href="#cb16-1" aria-hidden="true" tabindex="-1"></a><span class="co">/* . echo| . */</span></span></code></pre></div>
<p>and repeat the process above</p>
<div class="sourceCode" id="cb17"><pre
class="sourceCode sh"><code class="sourceCode bash"><span id="cb17-1"><a href="#cb17-1" aria-hidden="true" tabindex="-1"></a><span class="ex">./adrian</span> <span class="op">&lt;</span>adrian.c <span class="op">&gt;</span> adecho.c</span></code></pre></div>
<p>The new file now contains all lines which match</p>
<pre><code>^.[^5|m^]*[m^]([e=p,;]|[^e=+p,;].*)$</code></pre>
<p>Compile and run. This is an <code>echo(1)</code> clone. Note the
efficient algorithm employed.</p>
<p>Two other adjustments to the first line also yield useful results. By
changing it to</p>
<div class="sourceCode" id="cb19"><pre class="sourceCode c"><code class="sourceCode c"><span id="cb19-1"><a href="#cb19-1" aria-hidden="true" tabindex="-1"></a><span class="co">/* . head; . */</span></span></code></pre></div>
<p>you can search for matches to</p>
<pre><code>^.[^W]*W..*$</code></pre>
<p>By some freak happenstance, lines of <code>adrian.c</code> which
match this regular expression form a unix <code>head(1)</code> command.
It prints the first ten lines of the file specified on the command line
or <code>adrian.c</code> if no file is specified (again this was changed
to <code>__FILE__</code>).</p>
<p>By setting the first line to</p>
<div class="sourceCode" id="cb21"><pre class="sourceCode c"><code class="sourceCode c"><span id="cb21-1"><a href="#cb21-1" aria-hidden="true" tabindex="-1"></a><span class="co">/* . basename . */</span></span></code></pre></div>
<p>a clone of the unix <code>basename(1)</code> command can be
unearthed. The automaton will search for</p>
<pre><code>^.[^j]*jr.*$</code></pre>
<p>on standard input. And the program which results by running
<code>adrian.c</code> through this filter requires two parameters. The
first is meant to be a filename, and the second, an extension. All
leading pathname components are removed from the filename, and the
extension is removed if present. The resulting base name is printed to
stdout.</p>
<p>Lastly, by setting the first line to</p>
<div class="sourceCode" id="cb23"><pre class="sourceCode c"><code class="sourceCode c"><span id="cb23-1"><a href="#cb23-1" aria-hidden="true" tabindex="-1"></a><span class="co">/* . sleep . */</span></span></code></pre></div>
<p>you can search for</p>
<pre><code>^.[^(~][^s]*sl.*$</code></pre>
<p>Filtering <code>adrian.c</code> through this search yields a clone of
the <code>sleep(1)</code> command. Invoke with a single integer
parameter, and it will pause for that many seconds.</p>
<p>If either <code>adbasename</code> or <code>adsleep</code> is invoked
with too few parameters, the program will print the error message:</p>
<blockquote>
<p>Segmentation fault (core dumped)</p>
</blockquote>
<p>(The exact text of the above error messages varies from machine to
machine.) The four programs which read from stdin require lines shorter
than 999 characters.</p>
<p>The other info files are <code>adrian.grep.[1-6]</code> which contain
the six examples that appear above, and from, which is used to emulate
the unix <code>from</code> command. For reasons of clarity, the name
<code>"from"</code> should probably not be changed if possible. I
wouldn’t want to be accused of confusing people by giving the input
files weird names.</p>
<p>If you want to change the default input filename (line 80) you must
be careful to choose a name that doesn’t match the wrong search
patterns, introducing extra lines into one of the programs (again, this
was changed to be <code>__FILE__</code>).</p>
<p>The program will produce at least one warning and possible several
when compiled depending on the compiler.</p>
<h2 id="copyright-and-cc-by-sa-4.0-license">Copyright and CC BY-SA 4.0
License:</h2>
<p>This file is Copyright (c) 2023 by Landon Curt Noll. All Rights
Reserved. You are free to share and adapt this file under the terms of
this license:</p>
<pre><code>Creative Commons Attribution-ShareAlike 4.0 International (CC BY-SA 4.0)</code></pre>
<p>For more information, see:
https://creativecommons.org/licenses/by-sa/4.0/</p>
<!-- START: this line starts content generated by: bin/gen-inventory.sh -->
<h1 id="inventory-for-1992adrian"><a name="inventory"></a>Inventory for
1992/adrian</h1>
<h2 id="primary-files">Primary files</h2>
<ul>
<li><a href="index.html">index.html</a> - winner home page</li>
<li><a
href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1992/adrian/adrian.c">adrian.c</a>
- winning source</li>
<li><a
href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1992/adrian/Makefile">Makefile</a>
- winner Makefile</li>
<li><a
href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1992/adrian/adrian.orig.c">adrian.orig.c</a>
- original source</li>
<li><a
href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1992/adrian/adrian.grep.1">adrian.grep.1</a>
- agrep script</li>
<li><a
href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1992/adrian/adrian.grep.2">adrian.grep.2</a>
- agrep script</li>
<li><a
href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1992/adrian/adrian.grep.3">adrian.grep.3</a>
- agrep script</li>
<li><a
href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1992/adrian/adrian.grep.4">adrian.grep.4</a>
- agrep script</li>
<li><a
href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1992/adrian/adrian.grep.5">adrian.grep.5</a>
- agrep script</li>
<li><a
href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1992/adrian/adrian.grep.from">adrian.grep.from</a>
- agrep script</li>
<li><a
href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1992/adrian/adrian.grep.try">adrian.grep.try</a>
- agrep script</li>
<li><a
href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1992/adrian/try.sh">try.sh</a>
- how to run</li>
<li><a href="1992_adrian.tar.bz2">1992_adrian.tar.bz2</a> - download
winning source</li>
</ul>
<h2 id="secondary-files">Secondary files</h2>
<ul>
<li><a
href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1992/adrian/.gitignore">.gitignore</a>
- list of files that should not be committed under git</li>
<li><a href=".path">.path</a> - directory path from top directory</li>
<li><a
href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1992/adrian/.winner.json">.winner.json</a>
- description of winner in JSON</li>
<li><a
href="https://github.com/ioccc-src/temp-test-ioccc/blob/master/1992/adrian/README.md">README.md</a>
- markdown source for index.html</li>
</ul>
<!-- END: next line ends content generated by: bin/gen-inventory.sh -->
<!-- START: this line starts content from: inc/after-content.default.html -->
<!-- END: this line ends content from: inc/after-content.default.html -->
<!-- START: this line starts content from: inc/end-rightcolumn.default.html -->
</div>
<!-- END: this line ends content from: inc/end-rightcolumn.default.html -->
<!-- START: this line starts content from: inc/end-row.default.html -->
</div>
<!-- END: this line ends content from: inc/end-row.default.html -->
<!-- START: this line starts content from: inc/footer.default.html -->
<div class="footer">
<hr>
<h2>Coda</h2>
<p><a href="https://validator.w3.org/nu/?doc=https%3A%2F%2Fioccc-src.github.io%2Ftemp-test-ioccc%2F1992%2Fadrian%2Findex.html">Nu HTML check this web page</a></p>
<p><a href="#top">Jump to top</a> <a href="#content">Jump to Content</a> <a href="#inventory">Jump to Inventory</a></p>
</div>
<!-- END: this line ends content from: inc/footer.default.html -->
<!-- START: this line starts content from: inc/bottom.default.html -->
</body>
</html>
<!-- END: this line ends content from: inc/bottom.default.html -->