codecombat/config.coffee

92 lines
3.1 KiB
CoffeeScript
Raw Normal View History

2014-01-03 13:32:13 -05:00
sysPath = require 'path'
startsWith = (string, substring) ->
string.lastIndexOf(substring, 0) is 0
exports.config =
server:
path: 'server.coffee'
paths:
'public': 'public'
conventions:
ignored: (path) -> startsWith(sysPath.basename(path), '_')
workers:
enabled: false # turned out to be much, much slower than without workers
files:
javascripts:
defaultExtension: 'coffee'
joinTo:
'javascripts/world.js': ///^(
(app[\/\\]lib[\/\\]world(?![\/\\]test))
|(app[\/\\]lib[\/\\]CocoClass.coffee)
|(app[\/\\]lib[\/\\]utils.coffee)
|(vendor[\/\\]scripts[\/\\]Box2dWeb-2.1.a.3)
|(vendor[\/\\]scripts[\/\\]string_score.js)
|(bower_components[\/\\]lodash[\/\\]dist[\/\\]lodash.js)
|(bower_components[\/\\]aether[\/\\]build[\/\\]aether.js)
)///
2014-01-03 13:32:13 -05:00
'javascripts/app.js': /^app/
'javascripts/vendor.js': ///^(
vendor[\/\\](?!scripts[\/\\]Box2d)
|bower_components
)///
'javascripts/vendor_with_box2d.js': ///^(
vendor[\/\\]
|bower_components # include box2dweb for profiling (and for IE9...)
)///
'javascripts/tome_aether.js': ///^(
(bower_components[\/\\]lodash[\/\\]dist[\/\\]lodash.js)
|(bower_components[\/\\]aether[\/\\]build[\/\\]aether.js)
)///
'test/javascripts/test.js': /^test[\/\\](?!vendor)/
'test/javascripts/test-vendor.js': /^test[\/\\](?=vendor)/
2014-01-03 13:32:13 -05:00
order:
before: [
2014-04-11 13:12:39 -04:00
'bower_components/jquery/dist/jquery.js'
2014-01-03 13:32:13 -05:00
'bower_components/lodash/dist/lodash.js'
'bower_components/backbone/backbone.js'
# Twitter Bootstrap jquery plugins
'bower_components/bootstrap/dist/bootstrap.js'
2014-01-03 13:32:13 -05:00
# CreateJS dependencies
'vendor/scripts/easeljs-NEXT.combined.js'
'vendor/scripts/preloadjs-NEXT.combined.js'
'vendor/scripts/soundjs-NEXT.combined.js'
'vendor/scripts/tweenjs-NEXT.combined.js'
'vendor/scripts/movieclip-NEXT.min.js'
# Validated Backbone Mediator dependencies
'bower_components/tv4/tv4.js'
2014-01-03 13:32:13 -05:00
# Aether before box2d for some strange Object.defineProperty thing
'bower_components/aether/build/aether.js'
2014-04-02 21:41:10 -04:00
'bower_components/d3/d3.min.js'
2014-01-03 13:32:13 -05:00
]
stylesheets:
defaultExtension: 'sass'
joinTo:
'stylesheets/app.css': /^(app|vendor|bower_components)/
2014-01-03 13:32:13 -05:00
order:
2014-04-02 17:40:06 -04:00
before: [
'app/styles/bootstrap.scss'
2014-04-03 14:43:09 -04:00
'vendor/styles/nanoscroller.scss'
2014-04-02 17:40:06 -04:00
]
2014-01-03 13:32:13 -05:00
templates:
defaultExtension: 'jade'
joinTo: 'javascripts/app.js'
framework: 'backbone'
plugins:
coffeelint:
pattern: /^app\/.*\.coffee$/
options:
line_endings:
value: "unix"
level: "error"
max_line_length:
level: "ignore"
no_trailing_whitespace:
level: "ignore" # PyCharm can't just autostrip for .coffee, needed for .jade
no_unnecessary_fat_arrows:
level: "ignore"
uglify:
output:
semicolons: false