better log messages

This commit is contained in:
Philipp Kunz 2016-04-02 01:20:52 +02:00
parent a3af90844a
commit 791eaefe3c
6 changed files with 10 additions and 6 deletions

3
dist/npmts.clean.js vendored
View File

@ -3,10 +3,11 @@
var plugins = require("./npmts.plugins"); var plugins = require("./npmts.plugins");
var paths = require("./npmts.paths"); var paths = require("./npmts.paths");
exports.run = function (configArg) { exports.run = function (configArg) {
plugins.beautylog.log("now cleaning up from previous builds"); plugins.beautylog.log("now cleaning up from previous builds...");
var done = plugins.Q.defer(); var done = plugins.Q.defer();
plugins.smartfile.fsaction.remove(paths.distDir) plugins.smartfile.fsaction.remove(paths.distDir)
.then(function () { .then(function () {
plugins.beautylog.ok("Cleaned up!");
done.resolve(configArg); done.resolve(configArg);
}); });
return done.promise; return done.promise;

View File

@ -12,7 +12,7 @@ exports.run = function () {
switch (config.mode) { switch (config.mode) {
case "default": case "default":
case "custom": case "custom":
plugins.beautylog.log("mode is " + config.mode.yellow); plugins.beautylog.ok("mode is " + config.mode.yellow);
done.resolve(config); done.resolve(config);
break; break;
default: default:

View File

@ -12,7 +12,7 @@ exports.doPublish = function () {
exports.run = function (configArg) { exports.run = function (configArg) {
var done = plugins.Q.defer(); var done = plugins.Q.defer();
var config = configArg; var config = configArg;
plugins.beautylog.log("now determining build options"); plugins.beautylog.log("now determining build options...");
//handle default mode //handle default mode
if (config.mode == "default") { if (config.mode == "default") {
config.typings = [ config.typings = [
@ -38,6 +38,7 @@ exports.run = function (configArg) {
config.docs ? void (0) : config.docs = {}; config.docs ? void (0) : config.docs = {};
config.docs.publish ? void (0) : config.docs.publish = false; config.docs.publish ? void (0) : config.docs.publish = false;
exports.doPublish() ? void (0) : config.docs.publish = false; exports.doPublish() ? void (0) : config.docs.publish = false;
plugins.beautylog.ok("build options are ready!");
done.resolve(config); done.resolve(config);
return done.promise; return done.promise;
var _a; var _a;

View File

@ -3,10 +3,11 @@ import plugins = require("./npmts.plugins");
import paths = require("./npmts.paths"); import paths = require("./npmts.paths");
export let run = function(configArg){ export let run = function(configArg){
plugins.beautylog.log("now cleaning up from previous builds"); plugins.beautylog.log("now cleaning up from previous builds...");
let done = plugins.Q.defer(); let done = plugins.Q.defer();
plugins.smartfile.fsaction.remove(paths.distDir) plugins.smartfile.fsaction.remove(paths.distDir)
.then(function(){ .then(function(){
plugins.beautylog.ok("Cleaned up!");
done.resolve(configArg); done.resolve(configArg);
}); });
return done.promise; return done.promise;

View File

@ -11,7 +11,7 @@ export var run = function(){
switch (config.mode){ switch (config.mode){
case "default": case "default":
case "custom": case "custom":
plugins.beautylog.log("mode is " + config.mode.yellow); plugins.beautylog.ok("mode is " + config.mode.yellow);
done.resolve(config); done.resolve(config);
break; break;
default: default:

View File

@ -15,7 +15,7 @@ export var run = function(configArg){
var done = plugins.Q.defer(); var done = plugins.Q.defer();
var config = configArg; var config = configArg;
plugins.beautylog.log("now determining build options"); plugins.beautylog.log("now determining build options...");
//handle default mode //handle default mode
if (config.mode == "default"){ if (config.mode == "default"){
@ -47,6 +47,7 @@ export var run = function(configArg){
config.docs.publish ? void(0) : config.docs.publish = false; config.docs.publish ? void(0) : config.docs.publish = false;
doPublish() ? void(0) : config.docs.publish = false; doPublish() ? void(0) : config.docs.publish = false;
plugins.beautylog.ok("build options are ready!");
done.resolve(config); done.resolve(config);
return done.promise; return done.promise;
}; };