mirror of
				https://github.com/strapi/strapi.git
				synced 2025-11-03 19:36:20 +00:00 
			
		
		
		
	Merge branch 'features/deits' into deits/export-archive
This commit is contained in:
		
						commit
						b69d73aa34
					
				@ -53,7 +53,12 @@ module.exports = async (opts) => {
 | 
			
		||||
   */
 | 
			
		||||
  const sourceOptions = {
 | 
			
		||||
    async getStrapi() {
 | 
			
		||||
      return strapi(await strapi.compile()).load();
 | 
			
		||||
      const appContext = await strapi.compile();
 | 
			
		||||
      const app = strapi(appContext);
 | 
			
		||||
 | 
			
		||||
      app.log.level = 'error';
 | 
			
		||||
 | 
			
		||||
      return app.load();
 | 
			
		||||
    },
 | 
			
		||||
  };
 | 
			
		||||
  const source = createLocalStrapiSourceProvider(sourceOptions);
 | 
			
		||||
@ -96,16 +101,7 @@ module.exports = async (opts) => {
 | 
			
		||||
    let resultData = [];
 | 
			
		||||
    logger.log(`Starting export...`);
 | 
			
		||||
 | 
			
		||||
    engine.progress.stream.on('start', ({ stage }) => {
 | 
			
		||||
      logger.log(`Starting transfer of ${stage}...`);
 | 
			
		||||
    });
 | 
			
		||||
 | 
			
		||||
    // engine.progress.stream..on('progress', ({ stage, data }) => {
 | 
			
		||||
    //   logger.log('progress');
 | 
			
		||||
    // });
 | 
			
		||||
 | 
			
		||||
    engine.progress.stream.on('complete', ({ stage, data }) => {
 | 
			
		||||
      logger.log(`...${stage} complete`);
 | 
			
		||||
    engine.progress.stream.on('complete', ({ data }) => {
 | 
			
		||||
      resultData = data;
 | 
			
		||||
    });
 | 
			
		||||
 | 
			
		||||
@ -113,7 +109,7 @@ module.exports = async (opts) => {
 | 
			
		||||
 | 
			
		||||
    // Build pretty table
 | 
			
		||||
    const table = new Table({
 | 
			
		||||
      head: ['Type', 'Count', 'Size'],
 | 
			
		||||
      head: ['Type', 'Count', 'Size'].map((text) => chalk.bold.blue(text)),
 | 
			
		||||
    });
 | 
			
		||||
 | 
			
		||||
    let totalBytes = 0;
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user