boilerplate.js
function(context) {
  const androidHome = process.env['ANDROID_HOME']
  const hasAndroidEnv = !context.strings.isBlank(androidHome)
  const hasAndroid = hasAndroidEnv && context.filesystem.exists(`${androidHome}/tools`) === 'dir'

  return Boolean(hasAndroid)
}
function(context) {
  const androidHome = process.env['ANDROID_HOME']
  const hasAndroidEnv = !context.strings.isBlank(androidHome)
  const hasAndroid = hasAndroidEnv && context.filesystem.exists(`${androidHome}/tools`) === 'dir'

  return Boolean(hasAndroid)
}
function ( context ) { const androidHome = process . env [ 'ANDROID_HOME' ] const hasAndroidEnv = ! context . strings . isBlank ( androidHome ) const hasAndroid = hasAndroidEnv && context . filesystem . exists ( ` ${ androidHome } ` ) === 'dir' return Boolean ( hasAndroid ) }
Is Android installed?

$ANDROID_HOME/tools folder has to exist.

@param {*} context - The gluegun context.
@returns {boolean}
Is Android installed?