<h2 id="why-use-plain-text">Why use plain text?</h2>
<ul>
<li>Portability</li>
<li>Use with Unix tools</li>
<li>Use with Ranger</li>
</ul>
<h2 id="ranger-for-the-win">Ranger for the win</h2>
<ul>
<li><a href="https://savannah.nongnu.org/projects/ranger">Ranger</a> is a free console file manager that gives you greater flexibility and a good overview of your files without having to leave your *nix console. It visualizes the directory tree in two dimensions: the directory hierarchy on one, lists of files on the other, with a preview to the right so you know where you’ll be going.</li>
<li>The scope functionality is where converting to text pays off. Located at <code>$HOME/.config/ranger/scope.sh</code>, scope is the feature that allows for file preview from inside the console. Text files are highlighted based on their file extension, for non-text files, different converters can be used to coerce the file into a text representation. Some items are available out of the box, but the configuration is written in such a way that any text can be presented in the preview screen.</li>
<li>The basic format of the scope switch statement is as follows:</li>
</ul>
<pre><code>case &quot;$extension&quot; in
    odt|odp)
        try odt2txt &quot;$path&quot; &amp;&amp; { dump | trim | fmt -s -w $width; exit 0; };;</code></pre>
<h2 id="tools-in-the-toolset">Tools in the toolset</h2>
<ul>
<li>atool</li>
<li>caca-utils</li>
<li>poppler-utils</li>
<li>catdoc</li>
<li>catppt</li>
<li>odt2txt</li>
<li>ods2tsv</li>
<li>docx2txt</li>
<li>xlsx2csv</li>
<li>mediainfo</li>
<li>lynx/w3m/elinks</li>
<li>highlight</li>
</ul>
<h2 id="bonus-tools">Bonus tools</h2>
<ul>
<li>q</li>
<li>jq</li>
<li>xmlstarlet</li>
</ul>
