Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
13 lines (10 sloc) 312 Bytes
fs = require 'fs'
coffee = require 'coffee-script'
exports.compile = (file, flags, callback) ->
fs.readFile file, 'utf8', (err, contents) ->
return callback err if err
try
output = coffee.compile contents, bare: 'bare' in flags
catch err
return callback err
callback null, output