Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

fixing the cake install script

  • Loading branch information...
commit 4e609a927ef704ed794436767e9ac6f3a6cf12eb 1 parent 05fae13
@jashkenas jashkenas authored
Showing with 4 additions and 5 deletions.
  1. +1 −1  Cakefile
  2. +3 −4 index.html
View
2  Cakefile
@@ -11,7 +11,7 @@ task 'install', 'install the `docco` command into /usr/local (or --prefix)', (op
lib = base + '/lib/docco'
exec([
'mkdir -p ' + lib
- 'cp -rf bin README resources vendor docco.coffee ' + lib
+ 'cp -rf bin README resources vendor lib ' + lib
'ln -sf ' + lib + '/bin/docco ' + base + '/bin/docco'
].join(' && '), (err, stdout, stderr) ->
if err then console.error stderr
View
7 index.html
@@ -75,7 +75,7 @@
<span class="nv">pygments = </span><span class="nx">spawn</span> <span class="s1">&#39;pygmentize&#39;</span><span class="p">,</span> <span class="p">[</span><span class="s1">&#39;-l&#39;</span><span class="p">,</span> <span class="nx">language</span><span class="p">.</span><span class="nx">name</span><span class="p">,</span> <span class="s1">&#39;-f&#39;</span><span class="p">,</span> <span class="s1">&#39;html&#39;</span><span class="p">,</span> <span class="s1">&#39;-O&#39;</span><span class="p">,</span> <span class="s1">&#39;encoding=utf-8&#39;</span><span class="p">]</span>
<span class="nv">output = </span><span class="s1">&#39;&#39;</span>
<span class="nx">pygments</span><span class="p">.</span><span class="nx">stderr</span><span class="p">.</span><span class="nx">addListener</span> <span class="s1">&#39;data&#39;</span><span class="p">,</span> <span class="p">(</span><span class="nx">error</span><span class="p">)</span> <span class="o">-&gt;</span>
- <span class="nx">puts</span> <span class="nx">error</span> <span class="k">if</span> <span class="nx">error</span>
+ <span class="nx">console</span><span class="p">.</span><span class="nx">error</span> <span class="nx">error</span> <span class="k">if</span> <span class="nx">error</span>
<span class="nx">pygments</span><span class="p">.</span><span class="nx">stdout</span><span class="p">.</span><span class="nx">addListener</span> <span class="s1">&#39;data&#39;</span><span class="p">,</span> <span class="p">(</span><span class="nx">result</span><span class="p">)</span> <span class="o">-&gt;</span>
<span class="nx">output</span> <span class="o">+=</span> <span class="nx">result</span> <span class="k">if</span> <span class="nx">result</span>
<span class="nx">pygments</span><span class="p">.</span><span class="nx">addListener</span> <span class="s1">&#39;exit&#39;</span><span class="p">,</span> <span class="o">-&gt;</span>
@@ -94,13 +94,12 @@
<span class="nv">html = </span><span class="nx">docco_template</span> <span class="p">{</span>
<span class="nx">title</span><span class="o">:</span> <span class="nx">title</span><span class="p">,</span> <span class="nx">sections</span><span class="o">:</span> <span class="nx">sections</span><span class="p">,</span> <span class="nx">sources</span><span class="o">:</span> <span class="nx">sources</span><span class="p">,</span> <span class="nx">path</span><span class="o">:</span> <span class="nx">path</span><span class="p">,</span> <span class="nx">destination</span><span class="o">:</span> <span class="nx">destination</span>
<span class="p">}</span>
- <span class="nx">puts</span> <span class="s2">&quot;docco: #{source} -&gt; #{dest}&quot;</span>
+ <span class="nx">console</span><span class="p">.</span><span class="nx">log</span> <span class="s2">&quot;docco: #{source} -&gt; #{dest}&quot;</span>
<span class="nx">fs</span><span class="p">.</span><span class="nx">writeFile</span> <span class="nx">dest</span><span class="p">,</span> <span class="nx">html</span></pre></div> </td> </tr> <tr id="section-7"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-7">&#182;</a> </div> <h3>Helpers &amp; Setup</h3> </td> <td class="code"> <div class="highlight"><pre></pre></div> </td> </tr> <tr id="section-8"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-8">&#182;</a> </div> <p>Require our external dependencies, including <strong>Showdown.js</strong>
(the JavaScript implementation of Markdown).</p> </td> <td class="code"> <div class="highlight"><pre><span class="nv">fs = </span><span class="nx">require</span> <span class="s1">&#39;fs&#39;</span>
<span class="nv">path = </span><span class="nx">require</span> <span class="s1">&#39;path&#39;</span>
<span class="nv">showdown = </span><span class="nx">require</span><span class="p">(</span><span class="s1">&#39;./../vendor/showdown&#39;</span><span class="p">).</span><span class="nx">Showdown</span>
-<span class="p">{</span><span class="nx">spawn</span><span class="p">,</span> <span class="nx">exec</span><span class="p">}</span> <span class="o">=</span> <span class="nx">require</span> <span class="s1">&#39;child_process&#39;</span>
-<span class="p">{</span><span class="nx">puts</span><span class="p">,</span> <span class="nx">print</span><span class="p">}</span> <span class="o">=</span> <span class="nx">require</span> <span class="s1">&#39;sys&#39;</span></pre></div> </td> </tr> <tr id="section-9"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-9">&#182;</a> </div> <p>A list of the languages that Docco supports, mapping the file extension to
+<span class="p">{</span><span class="nx">spawn</span><span class="p">,</span> <span class="nx">exec</span><span class="p">}</span> <span class="o">=</span> <span class="nx">require</span> <span class="s1">&#39;child_process&#39;</span></pre></div> </td> </tr> <tr id="section-9"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-9">&#182;</a> </div> <p>A list of the languages that Docco supports, mapping the file extension to
the name of the Pygments lexer and the symbol that indicates a comment. To
add another language to Docco's repertoire, add it here.</p> </td> <td class="code"> <div class="highlight"><pre><span class="nv">languages =</span>
<span class="s1">&#39;.coffee&#39;</span><span class="o">:</span>
Please sign in to comment.
Something went wrong with that request. Please try again.