var os = require('os'), dns = require('dns'), util = require('util'), colors = require('colors'), pubsub = require('event-pubsub'), eventParser = require('./lib/eventParser.js'), Client = require('./lib/client.js'), Server = require('./lib/socketServer.js'); colors.setTheme( { good : 'green', notice : 'yellow', warn : 'red', error : 'redBG', debug : 'magenta', variable: 'cyan', data : 'blue' } ); var IPType=os.networkInterfaces()[ Object.keys(os.networkInterfaces())[0] ][0].family var defaults={ appspace : 'app.', socketRoot : '/tmp/', networkHost : (IPType=='IPv6')? '::1' : '127.0.0.1', networkPort : 8000, id : os.hostname(), encoding : 'utf8', rawBuffer : false, silent : false, maxConnections : 100, retry : 500, maxRetries : Infinity, stopRetrying : false, IPType : IPType, tls : false } var ipc = { config : defaults, connectTo : connect, connectToNet: connectNet, disconnect : disconnect, serve : serve, serveNet : serveNet, of : {}, server : false, log : log } function log(){ if(ipc.config.silent) return; var args=Array.prototype.slice.call(arguments); for(var i=0, count=args.length; i