shortcake
Version:
Asynchronous invoke and other goodies for cake.
18 lines (12 loc) • 310 B
text/coffeescript
import log from './log'
# Keep track of running tasks
runningTasks = {}
running = (name) ->
return runningTasks[name]
running.start = (name) ->
log.info 'running', name
runningTasks[name] = true
running.stop = (name) ->
log.info 'stopped', name
runningTasks[name] = false
export default running