function indexationOption() {
    return new Promise((resolve, reject) => {
        logger_1.logger.log('info', `Starting indexation...`);
        indexation(configContent.previousCacheDir)
            .on('indexDone', () => {
            logger_1.logger.log('success', `Indexation done\n`);
            resolve();
        })
            .on('indexError', (err) => {
            logger_1.logger.log('error', `${err}`);
            reject(err);
        });
    });
}
function indexationOption() {
    return new Promise((resolve, reject) => {
        logger_1.logger.log('info', `Starting indexation...`);
        indexation(configContent.previousCacheDir)
            .on('indexDone', () => {
            logger_1.logger.log('success', `Indexation done\n`);
            resolve();
        })
            .on('indexError', (err) => {
            logger_1.logger.log('error', `${err}`);
            reject(err);
        });
    });
}
function indexationOption ( ) { return new Promise ( ( resolve , reject ) => { logger_1 . logger . log ( 'info' , ` ` ) ; indexation ( configContent . previousCacheDir ) . on ( 'indexDone' , ( ) => { logger_1 . logger . log ( 'success' , ` \n ` ) ; resolve ( ) ; } ) . on ( 'indexError' , ( err ) => { logger_1 . logger . log ( 'error' , ` ${ err } ` ) ; reject ( err ) ; } ) ; } ) ; }
/*
function indexationOption that return a Promise object. This function will be called
if the "-i" option given in command line. Starting the indexation of the
cache dir path given is ./config.json file.
/ * function indexationOption that return a Promise object . This function will be called if the - i option given in command line . Starting the indexation of the cache dir path given is . / config . json file .