eddie
Artifact [1868628a17]
Not logged in
Public Repositories
mwm's Repositories

Artifact 1868628a1792ff3a10a5dba6a1dc94621def191d:


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  <meta http-equiv="Content-Style-Type" content="text/css" />
  <meta name="generator" content="pandoc" />
  <title>eddie(1)</title>
  <style type="text/css">code{white-space: pre;}</style>
</head>
<body>
<div id="header">
<h1 class="title">eddie(1)</h1>
</div>
<h1 id="name">NAME</h1>
<p>eddie - run haskell filters from the command line</p>
<h1 id="synopsys">SYNOPSYS</h1>
<p><strong>eddie</strong> [ <em>options</em> ] [ <em>expr</em> ] <em>file</em> ...</p>
<h1 id="description">DESCRIPTION</h1>
<p><strong>eddie</strong> evalutes the provided <em>expression</em> on either the contents of <em>the file</em> arguments concatenated together, or standard input if no *file arguments are present.</p>
<p>The <strong>--line</strong>, <strong>--file</strong> and <strong>--list</strong> options can be used to cause <em>expression</em> to be used to process each line, each file, or a list of files or lines respectively.</p>
<p>The prelude, <code>Data.List</code> and <code>Data.Char</code> modules are available for building expressions. Other modules may be added with the <strong>--Modules</strong> and <strong>--modules</strong> options.</p>
<h1 id="options">OPTIONS</h1>
<dl>
<dt><strong>--expr</strong></dt>
<dd><p>The <strong>--expr</strong> <em>expr</em> (short form <strong>-e</strong> <em>expr</em> ) option concatenates it's value to the haskell expression being evaluated with a newline separator. Multiple occurrences can be used to build up a multi-line expression.</p>
<p>If no <strong>-e</strong> <em>expr</em> option is present, the first non-flag argument will be used for the haskell expression.</p>
</dd>
<dt><strong>--line</strong></dt>
<dd><p>The <strong>--line</strong> (short form <strong>-l</strong>) option causes <strong>eddie</strong> to process input line at a time. The <em>expr</em> will be run on each line and the results concatenated together (using unlines).</p>
<p>The command</p>
<pre><code>eddie -l *expr file* ...</code></pre>
<p>is equivalent to the command</p>
<pre><code>eddie &quot;unlines . map *expr*  . lines&quot; *file* ...</code></pre>
</dd>
<dt><strong>--file</strong></dt>
<dd><p>The <strong>--file</strong> (short form <strong>-f</strong>) causes each file to be processed individually.</p>
<p>Note that the <strong>-l</strong> and <strong>-f</strong> options cannot be used together.</p>
</dd>
<dt><strong>--list</strong></dt>
<dd><p>The <strong>--list</strong> (short form <strong>-L</strong>) option causes <strong>eddie</strong> to pass the expression a list of lines or files. This requires one of the <strong>-l</strong> or <strong>-f</strong> options be used.</p>
<p>The command</p>
<pre><code>eddie -lL *expr file* ...</code></pre>
<p>is equivalent to the command</p>
<pre><code>eddie &quot;unlines . *expr* . lines&quot; filei ...</code></pre>
</dd>
<dt><strong>--binary</strong></dt>
<dd>The <strong>--binary</strong> (short form <strong>-b</strong>) option switches the output mode to binary. It also disables the maybe newline processing. Normally <strong>eddie</strong> will output a final newline if the last character of the input is not a newline to place the prompt properly. If the <strong>-b</strong> option is used, the final newline will not be output.
</dd>
<dt><strong>--modules</strong></dt>
<dd>The <strong>--modules</strong> <em>name</em> (short form <strong>-m</strong> <em>name</em>) option is used to import module <em>name</em> into haskell before evaluating the expression.
</dd>
<dt><strong>--Modules</strong></dt>
<dd>The <strong>--Modules</strong> <em>name</em>,<em>as</em> (short form <strong>-M</strong> <em>name</em>,<em>as</em>) option imports the <em>name</em> module using a qualified import with an as clause, with <em>as</em> being the value for the as clause.
</dd>
</dl>
<h1 id="diagnostics">DIAGNOSTICS</h1>
<p>If the command runs with no problems, eddie will exit with a status of 0. If there are problems with the options, such that the expression is never evaluated, then eddie will exit with a status of 1. If haskell returns an error - probably a compilation problem - then eddie will exit with the status of 2.</p>
<h1 id="see-also">SEE ALSO</h1>
<p>The wiki at <a href="https://chiselapp.com/user/mwm/repository/eddie/wcontent" class="uri">https://chiselapp.com/user/mwm/repository/eddie/wcontent</a> for examples.</p>
<h1 id="bugs">BUGS</h1>
<p>See the issues list at <a href="https://chiselapp.com/user/mwm/repository/eddie/rptview?rn=1" class="uri">https://chiselapp.com/user/mwm/repository/eddie/rptview?rn=1</a>.</p>
<h1 id="author">AUTHOR</h1>
<p>Mike Meyer <script type="text/javascript">
<!--
h='&#x6d;&#x69;&#114;&#x65;&#100;&#46;&#x6f;&#114;&#x67;';a='&#64;';n='&#x6d;&#x77;&#x6d;';e=n+a+h;
document.write('<a h'+'ref'+'="ma'+'ilto'+':'+e+'" clas'+'s="em' + 'ail">'+e+'<\/'+'a'+'>');
// -->
</script><noscript>&#x6d;&#x77;&#x6d;&#32;&#x61;&#116;&#32;&#x6d;&#x69;&#114;&#x65;&#100;&#32;&#100;&#x6f;&#116;&#32;&#x6f;&#114;&#x67;</noscript></p>
</body>
</html>