   dir     = args.dir
   wrench.rmdirSyncRecursive dir  if fs.existsSync(dir)
 
-
 # var _linkPlugin = function(callback){
 #   var origin = path.resolve(process.cwd(), '..');
 #   var dist = path.resolve(process.cwd(), 'node_modules', pkg.name);
 #   fs.symlink(origin, dist, callback);
 # };
-_liftWithTwoSockets = (options, callback) ->
+
+liftWithTwoSockets = (options, callback) ->
   if typeof options is "function"
     callback = options
     options = null
-  _lift options, (err, sails) ->
+  lift options, (err, sails) ->
     return callback(err)  if err
     socket1 = _ioClient.connect("http://localhost:1342",
       "force new connection": true

      socket2.on "connect", ->
        callback null, sails, socket1, socket2

_buildAndLiftWithTwoSockets = (appName, options, callback) ->
  if typeof options is "function"
    callback = options
    options = null
  _build appName, ->
    _liftWithTwoSockets options, callback


# Exports
module.exports =
  build: _build
  clean: _clean

  # linkPlugin                 : _linkPlugin,
  lift: _lift
  buildAndLift: _buildAndLift

# liftWithTwoSockets         : _liftWithTwoSockets,
# buildAndLiftWithTwoSockets : _buildAndLiftWithTwoSockets

      sails.kill = sails.lower
      done null, sails

###
Concatenate build and lift actions
@param  {[type]}   options Sails option object
@param  {Function} done    Callback
@return {[type]}           Callback
###
buildAndLift = (options, done) ->
  build -> lift options, done

###
Clean a proyect
###
clean = -> # dir
  args = Args([
    {dir:     Args.STRING   | Args.Optional, _default: appName_path}
  ], arguments)
