import inquirer from 'inquirer' ; import { Plugin } from './load_kibana_platform_plugin' ; export async function resolveKibanaVersion ( option , plugin ) { const preselectedVersion = option || plugin . manifest . kibanaVersion || plugin . manifest . version ; if ( preselectedVersion && preselectedVersion !== 'kibana' ) { return preselectedVersion ; } const answers = await inquirer . prompt ( [ { type : 'input' , name : 'kibanaVersion' , message : 'What version of Kibana are you building for?' , } , ] ) ; return answers . kibanaVersion ; }