 #
 # Our main bin code, called when executing the `kdc-plus` command.
 #
-fs          = require 'fs'
-path        = require 'path'
-compilers   = require '../lib/compilers'
-maniutils   = require '../lib/maniutils'
+fs                = require 'fs'
+path              = require 'path'
+{CoffeeTransform} = require '../lib/streams/coffee'
+{Commojs}         = require '../lib/streams/commonjs'
+{LoadMulti}       = require '../lib/streams/load'
+maniutils         = require '../lib/maniutils'
 
 
 

      log failure for failure in vfails
      return process.exit 1

    files = manifest.source.blocks.app.files

    compiler = compilers[manifest.compiler]

    compiler files, (err, out) ->
      if err?
        log "Error Compiling KDApp: #{err.message}"
        return process.exit 1

      fs.writeFile path.join(appPath, 'indexj.js'), out, (err) ->
        if err?
          log "Error Saving Compiled KDApp: #{err.message}"
          return process.exit 1




  opts.version '@@version'
  opts.usage '[options] [kdapp directory]'
  opts.parse argv

  #Hack for now
  opts.coffee ?= true

  [appPath, unhandledArgs] = opts.args

