code: function getLaunchFolder() {
  	var result
  
  	var requireMainFilename = require && require.main && require.main.filename
  	if (requireMainFilename) result = path.dirname(requireMainFilename)
  	else if (__dirname) {
  		var myFolderName = path.basename(__dirname)
  		if (myFolderName === 'test') result = path.join(__dirname, '..')
  		else {
  			var firstNodeModules = __dirname.indexOf('/node_modules/')
  			if (~firstNodeModules) result = __dirname.substring(0, firstNodeModules)
  		}
  	}
  	if (!result) result = process.cwd()
  
  	return result
  }
docs: /*
  Find the app's launch folder
  1. require.main.filename
  2. One level above if foldername is 'test'
  3. Above the first occurence of '/node_modules' (does not work for symlinked modules)
  4. current working directory
  return value: string absolute path to folder where the initially launched script is located