fix assets management
This commit is contained in:
		
							
								
								
									
										3
									
								
								dist/npmts.assets.js
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										3
									
								
								dist/npmts.assets.js
									
									
									
									
										vendored
									
									
								
							@@ -8,11 +8,12 @@ exports.run = function (configArg) {
 | 
				
			|||||||
    var config = configArg;
 | 
					    var config = configArg;
 | 
				
			||||||
    npmts_promisechain_1.npmtsOra.text("now looking at " + "required assets".yellow);
 | 
					    npmts_promisechain_1.npmtsOra.text("now looking at " + "required assets".yellow);
 | 
				
			||||||
    if (config.cli == true) {
 | 
					    if (config.cli == true) {
 | 
				
			||||||
        plugins.smartfile.fs.copy(plugins.path.join(paths.npmtsAssetsDir, "cli.js"), paths.distDir);
 | 
					        plugins.smartfile.fs.copySync(plugins.path.join(paths.npmtsAssetsDir, "cli.js"), plugins.path.join(paths.distDir, "cli.js"));
 | 
				
			||||||
        plugins.beautylog.ok("installed CLI assets!");
 | 
					        plugins.beautylog.ok("installed CLI assets!");
 | 
				
			||||||
        done.resolve(config);
 | 
					        done.resolve(config);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    else {
 | 
					    else {
 | 
				
			||||||
 | 
					        plugins.beautylog.ok("No additional assets required!");
 | 
				
			||||||
        done.resolve(config);
 | 
					        done.resolve(config);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    return done.promise;
 | 
					    return done.promise;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -8,10 +8,14 @@ export var run = function(configArg){
 | 
				
			|||||||
    let config = configArg;
 | 
					    let config = configArg;
 | 
				
			||||||
    npmtsOra.text("now looking at " + "required assets".yellow);
 | 
					    npmtsOra.text("now looking at " + "required assets".yellow);
 | 
				
			||||||
    if(config.cli == true){
 | 
					    if(config.cli == true){
 | 
				
			||||||
        plugins.smartfile.fs.copy(plugins.path.join(paths.npmtsAssetsDir,"cli.js"),paths.distDir);
 | 
					        plugins.smartfile.fs.copySync(
 | 
				
			||||||
 | 
					            plugins.path.join(paths.npmtsAssetsDir,"cli.js"),
 | 
				
			||||||
 | 
					            plugins.path.join(paths.distDir,"cli.js")
 | 
				
			||||||
 | 
					        );
 | 
				
			||||||
        plugins.beautylog.ok("installed CLI assets!");
 | 
					        plugins.beautylog.ok("installed CLI assets!");
 | 
				
			||||||
        done.resolve(config);
 | 
					        done.resolve(config);
 | 
				
			||||||
    } else {
 | 
					    } else {
 | 
				
			||||||
 | 
					        plugins.beautylog.ok("No additional assets required!")
 | 
				
			||||||
        done.resolve(config);
 | 
					        done.resolve(config);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    return done.promise;
 | 
					    return done.promise;
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user