-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of git://github.com/jashkenas/coffee-script
Conflicts: src/coffee-script.coffee src/nodes.coffee
- Loading branch information
Showing
84 changed files
with
1,889 additions
and
825 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
coffeescript.org |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,114 @@ | ||
|
||
____ | ||
| _ \ | ||
.- ----------- -. | |_) | ___ ___ _ __ | ||
( (.} {.} {.} } ) | _ < / _ \/ _ \ '__| | ||
|`-..________ ..-'| | |_) | __/ __/ | | ||
| | |____/ \___|\___|_| | ||
| ;--. | ||
| (__ \ _____ _ _ | ||
| | ) ) / ____| (_) | | | ||
| |/ / | (___ ___ _ __ _ _ __ | |_ | ||
| ( / \___ \ / __| '__| | '_ \| __| | ||
| |/ ____) | (__| | | | |_) | |_ | ||
| | |_____/ \___|_| |_| .__/ \__| | ||
`-.._________..-' | | | ||
|_| | ||
|
||
* support for @_private | ||
* support for @[$private + 'private'] | ||
* support for goog.provide via --goog switch | ||
* include goog.dom as dom via --goog switch | ||
* auto include base class | ||
* support for enumeration | ||
|
||
|
||
|
||
enumeration builder.ui.ColumnLayout.ORIENTATION | ||
VERTICAL: 'vertical' | ||
BLA: 'horizontal' | ||
|
||
```coffee | ||
include goog.dom as dom | ||
include builder.ui.Component as bui | ||
|
||
class builder.ui.ColumnLayout extends goog.ui.Component | ||
constructor: -> | ||
dom.getElementByClass 'xxx' | ||
|
||
|
||
enumeration builder.ui.ColumnLayout.ORIENTATION | ||
VERTICAL: 'vertical' | ||
BLA: 'horizontal' | ||
``` | ||
|
||
```javascript | ||
goog.provide('builder.ui.ColumnLayout'); | ||
goog.provide('builder.ui.ColumnLayout.ORIENTATION'); | ||
|
||
goog.require('builder.ui.Component'); | ||
goog.require('goog.dom'); | ||
|
||
goog.scope(function () { | ||
var bui = 'builder.ui.Component'; | ||
var dom = 'goog.dom'; | ||
|
||
|
||
builder.ui.ColumnLayout = (function (_super) { | ||
var $private; | ||
|
||
__extends(ColumnLayout, _super); | ||
|
||
$private = '$builder_ui_ColumnLayout_'; | ||
|
||
function ColumnLayout() { | ||
dom.getElementByClass('xxx'); | ||
} | ||
|
||
return ColumnLayout; | ||
|
||
})(goog.ui.Component); | ||
|
||
builder.ui.ColumnLayout.ORIENTATION = { | ||
VERTICAL: 'vertical', | ||
HORIZONTAL: 'horizontal' | ||
}; | ||
|
||
}); // close goog.scope() | ||
``` | ||
|
||
|
||
|
||
---------------------------------------------------------------- | ||
|
||
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.) | ||
|
||
Execute a script: | ||
coffee /path/to/script.coffee | ||
|
||
Compile a script: | ||
coffee -c /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 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
### | ||
CoffeeScript Compiler v1.2.0 | ||
CoffeeScript Compiler v1.3.1 | ||
Released under the MIT License | ||
### | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,6 +8,5 @@ else | |
|
||
date = if friday then sue else jill | ||
|
||
options or= defaults | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
solipsism = true if mind? and not world? | ||
|
||
speed ?= 75 | ||
speed = 0 | ||
speed ?= 15 | ||
|
||
footprints = yeti ? "bear" | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,9 @@ | ||
numbers = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] | ||
numbers = [1, 2, 3, 4, 5, 6, 7, 8, 9] | ||
|
||
copy = numbers[0...numbers.length] | ||
start = numbers[0..2] | ||
|
||
middle = copy[3..6] | ||
middle = numbers[3...6] | ||
|
||
end = numbers[6..] | ||
|
||
copy = numbers[..] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.