         s = replace_all(s, "{#{k}}", "#{v}")
     #log('s = ', s)
     return s
+
+# split on whitespace
+split = (s) -> s.match(/\S+/g)
 
 run = (s, cb) ->
     log("running '#{s}'")

# Periodically check for idle running projects, and if so switch
# them from the run=true to run=false.
idle_timeout_check = () ->
    now = new Date()
    for project_id, project of projects
        if project.run and project.idle_timeout and now - project.last_edited >= project.idle_timeout * 1000*60


NOTE: This code doesn't depend on the rest of the SMC library.
###

IDLE_TIMEOUT_INTERVAL_M = 1  # check for need to idle timeout projects with this frequently

{DEFAULT_QUOTAS} = require('./upgrade-spec.coffee')

