import ora = require ( 'ora' ) ; import * as colors from 'colors' ; /** Holds spinner instances */ const cache = { } ; author Mitch Pierias <github.com/MitchPierias>
 *  param text export const create = ( text ) => { if ( cache . spinner ) { cache . spinner . succeed ( ) ; delete cache . spinner ; } update ( text ) ; } ; author Mitch Pierias <github.com/MitchPierias>
 *  param text export const update = ( text ) => { if ( ! cache . spinner ) cache . spinner = ora ( { text : colors . white ( text ) , color : 'magenta' , } ) . start ( ) ; cache . spinner . text = colors . white ( text ) ; } ; author Mitch Pierias <github.com/MitchPierias>
 *  param message param isError export const end = ( message = '' , isError = false ) => { if ( ! cache . spinner ) return ; if ( isError ) { cache . spinner . fail ( colors . cyan ( message ) ) ; } else { cache . spinner . succeed ( colors . cyan ( message ) ) ; } delete cache . spinner ; } ; author Mitch Pierias <github.com/MitchPierias>
 *  param message export const fail = ( message ) => { end ( message , true ) ; } ;