Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
74 changes: 28 additions & 46 deletions README
Original file line number Diff line number Diff line change
@@ -1,48 +1,30 @@
=
{
} } {
{ { } }
} }{ {
{ }{ } } _____ __ __
( }{ }{ { ) / ____| / _|/ _|
.- { { } { }} -. | | ___ | |_| |_ ___ ___
( ( } { } { } } ) | | / _ \| _| _/ _ \/ _ \
|`-..________ ..-'| | |___| (_) | | | || __/ __/
| | \_____\___/|_| |_| \___|\___|
| ;--.
| (__ \ _____ _ _
| | ) ) / ____| (_) | |
| |/ / | (___ ___ _ __ _ _ __ | |_
| ( / \___ \ / __| '__| | '_ \| __|
| |/ ____) | (__| | | | |_) | |_
| | |_____/ \___|_| |_| .__/ \__|
`-.._________..-' | |
|_|
_____ __ __
{ / ____| / _|/ _|
} } { | | ___ | |_| |_ ___ ___
{ { } } | | / _ \| _| _/ _ \/ _ \
} }{ { | |___| (_) | | | || __/ __/
{ }{ } } \_____\___/|_| |_| \___|\___|
( }{ }{ { )
.- { { } { }} -. _____ _ _
( ( } { } { } } ) / ____| (_) | |
|`-..________ ..-'| | (___ ___ _ __ _ _ __ | |_
| | \___ \ / __| '__| | '_ \| __|
| ;--. ____) | (__| | | | |_) | |_
| (__ \ |_____/ \___|_| |_| .__/ \__|
| | ) ) | |
| |/ / |_|
| ( / _____ _
| |/ _ / ____| |
| | _| |_ | | | | ___ ___ _ _ _ __ ___
`-.._________..-' |_ _| | | | |/ _ \/ __| | | | '__/ _ \
|_| | |____| | (_) \__ \ |_| | | | __/
\_____|_|\___/|___/\__,_|_| \___|




This fork of Jeremy Ashkenas's awesome CoffeeScript contains an extra flag to emit code for Google's Closure compiler + library.
Initial work done by Michael Bolin; documentation at http://bolinfest.com/coffee/features.html.
Just run `coffee` as you normally would, except with a `--google` flag.


CoffeeScript is a little language that compiles into JavaScript.

Install Node.js, and then the CoffeeScript compiler:
sudo bin/cake install

Or, if you have the Node Package Manager installed:
npm install -g coffee-script
(Leave off the -g if you don't wish to install globally.)

Compile a script:
coffee /path/to/script.coffee

For documentation, usage, and examples, see:
http://coffeescript.org/

To suggest a feature, report a bug, or general discussion:
http://github.com/jashkenas/coffee-script/issues/

If you'd like to chat, drop by #coffeescript on Freenode IRC,
or on webchat.freenode.net.

The source repository:
git://github.com/jashkenas/coffee-script.git

All contributors are listed here:
http://github.com/jashkenas/coffee-script/contributors
2 changes: 1 addition & 1 deletion documentation/coffee/block_comment.coffee
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
###
CoffeeScript Compiler v1.1.1
CoffeeScript Compiler v1.1.2
Released under the MIT License
###

Expand Down
4 changes: 4 additions & 0 deletions documentation/css/docs.css
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,10 @@ code, pre, tt, textarea {
font-weight: normal;
color: black;
}
.timestamp small {
font-size: 11px;
text-transform: uppercase;
}
div.code {
position: relative;
background: #fff;
Expand Down
4 changes: 2 additions & 2 deletions documentation/docs/browser.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@
<span class="nv">xhr.onreadystatechange = </span><span class="o">-&gt;</span>
<span class="k">if</span> <span class="nx">xhr</span><span class="p">.</span><span class="nx">readyState</span> <span class="o">is</span> <span class="mi">4</span>
<span class="k">if</span> <span class="nx">xhr</span><span class="p">.</span><span class="nx">status</span> <span class="k">in</span> <span class="p">[</span><span class="mi">0</span><span class="p">,</span> <span class="mi">200</span><span class="p">]</span>
<span class="nx">CoffeeScript</span><span class="p">.</span><span class="nx">run</span> <span class="nx">xhr</span><span class="p">.</span><span class="nx">responseText</span>
<span class="nx">CoffeeScript</span><span class="p">.</span><span class="nx">run</span> <span class="nx">xhr</span><span class="p">.</span><span class="nx">responseText</span>
<span class="k">else</span>
<span class="k">throw</span> <span class="k">new</span> <span class="nb">Error</span> <span class="s2">&quot;Could not load #{url}&quot;</span>
<span class="nx">callback</span><span class="p">()</span> <span class="k">if</span> <span class="nx">callback</span>
<span class="nx">callback</span><span class="p">()</span> <span class="k">if</span> <span class="nx">callback</span>
<span class="nx">xhr</span><span class="p">.</span><span class="nx">send</span> <span class="kc">null</span></pre></div> </td> </tr> <tr id="section-6"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-6">&#182;</a> </div> <p>Activate CoffeeScript in the browser by having it compile and evaluate
all script tags with a content-type of <code>text/coffeescript</code>.
This happens on page load.</p> </td> <td class="code"> <div class="highlight"><pre><span class="nv">runScripts = </span><span class="o">-&gt;</span>
Expand Down
2 changes: 1 addition & 1 deletion documentation/docs/cake.html
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
<span class="nv">spaces = </span><span class="k">if</span> <span class="nx">spaces</span> <span class="o">&gt;</span> <span class="mi">0</span> <span class="k">then</span> <span class="nb">Array</span><span class="p">(</span><span class="nx">spaces</span> <span class="o">+</span> <span class="mi">1</span><span class="p">).</span><span class="nx">join</span><span class="p">(</span><span class="s1">&#39; &#39;</span><span class="p">)</span> <span class="k">else</span> <span class="s1">&#39;&#39;</span>
<span class="nv">desc = </span><span class="k">if</span> <span class="nx">task</span><span class="p">.</span><span class="nx">description</span> <span class="k">then</span> <span class="s2">&quot;# #{task.description}&quot;</span> <span class="k">else</span> <span class="s1">&#39;&#39;</span>
<span class="nx">console</span><span class="p">.</span><span class="nx">log</span> <span class="s2">&quot;cake #{name}#{spaces} #{desc}&quot;</span>
<span class="nx">console</span><span class="p">.</span><span class="nx">log</span> <span class="nx">oparse</span><span class="p">.</span><span class="nx">help</span><span class="p">()</span> <span class="k">if</span> <span class="nx">switches</span><span class="p">.</span><span class="nx">length</span></pre></div> </td> </tr> <tr id="section-10"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-10">&#182;</a> </div> <p>Print an error and exit when attempting to all an undefined task.</p> </td> <td class="code"> <div class="highlight"><pre><span class="nv">missingTask = </span><span class="p">(</span><span class="nx">task</span><span class="p">)</span> <span class="o">-&gt;</span>
<span class="nx">console</span><span class="p">.</span><span class="nx">log</span> <span class="nx">oparse</span><span class="p">.</span><span class="nx">help</span><span class="p">()</span> <span class="k">if</span> <span class="nx">switches</span><span class="p">.</span><span class="nx">length</span></pre></div> </td> </tr> <tr id="section-10"> <td class="docs"> <div class="pilwrap"> <a class="pilcrow" href="#section-10">&#182;</a> </div> <p>Print an error and exit when attempting to call an undefined task.</p> </td> <td class="code"> <div class="highlight"><pre><span class="nv">missingTask = </span><span class="p">(</span><span class="nx">task</span><span class="p">)</span> <span class="o">-&gt;</span>
<span class="nx">console</span><span class="p">.</span><span class="nx">log</span> <span class="s2">&quot;No such task: \&quot;#{task}\&quot;&quot;</span>
<span class="nx">process</span><span class="p">.</span><span class="nx">exit</span> <span class="mi">1</span>

Expand Down
Loading