Comparing version 0.38.1 to 0.40.0
@@ -32,3 +32,3 @@ declare module 'boost/lib/helpers/formatModuleName' { | ||
import { Struct } from 'optimal'; | ||
import { Context, Status, Partial } from 'boost/lib/types'; | ||
import { Context, Status } from 'boost/lib/types'; | ||
export interface TaskInterface { | ||
@@ -75,5 +75,2 @@ status: Status; | ||
import { TaskInterface } from 'boost/lib/Task'; | ||
export type Partial<T> = { | ||
[P in keyof T]?: T[P]; | ||
}; | ||
export interface Context { | ||
@@ -171,3 +168,2 @@ [key: string]: any; | ||
import { Struct } from 'optimal'; | ||
import { Partial } from 'boost/lib/types'; | ||
export interface ModuleInterface { | ||
@@ -217,3 +213,3 @@ moduleName: string; | ||
import { ReporterInterface } from 'boost/lib/Reporter'; | ||
import { ConsoleOptions, Partial } from 'boost/lib/types'; | ||
import { ConsoleOptions } from 'boost/lib/types'; | ||
export interface ConsoleInterface extends EmitterInterface { | ||
@@ -293,3 +289,3 @@ options: ConsoleOptions; | ||
import { ReporterInterface } from 'boost/lib/Reporter'; | ||
import { ToolConfig, ToolOptions, PackageConfig, Partial } from 'boost/lib/types'; | ||
import { ToolConfig, ToolOptions, PackageConfig } from 'boost/lib/types'; | ||
export interface ToolInterface extends EmitterInterface { | ||
@@ -299,3 +295,2 @@ argv: string[]; | ||
console: ConsoleInterface; | ||
debug: debug.IDebugger; | ||
options: ToolOptions; | ||
@@ -305,2 +300,3 @@ package: PackageConfig; | ||
createDebugger(...namespaces: string[]): debug.IDebugger; | ||
debug(message: string, ...args: any[]): this; | ||
log(message: string, ...args: any[]): this; | ||
@@ -314,3 +310,3 @@ logError(message: string, ...args: any[]): this; | ||
console: ConsoleInterface; | ||
debug: debug.IDebugger; | ||
debugger: debug.IDebugger; | ||
initialized: boolean; | ||
@@ -323,2 +319,3 @@ options: ToolOptions; | ||
createDebugger(...namespaces: string[]): debug.IDebugger; | ||
debug(message: string, ...args: any[]): this; | ||
exit(message: string | Error | null, code?: number): this; | ||
@@ -367,3 +364,3 @@ getPlugin(name: string): Tp; | ||
import { ToolInterface } from 'boost/lib/Tool'; | ||
import { Context, Partial } from 'boost/lib/types'; | ||
import { Context } from 'boost/lib/types'; | ||
export interface CommandOptions extends Struct { | ||
@@ -419,2 +416,3 @@ sync?: boolean; | ||
export { ConfigLoader, ConsoleInterface, Emitter, EmitterInterface, Event, ExitError, Module, ModuleInterface, ModuleLoader, Pipeline, Plugin, PluginInterface, Reporter, ReporterInterface, Routine, Tool, ToolInterface }; | ||
export { Context, ConsoleOptions, ToolConfig, ToolOptions, PackageConfig, ReportParams, ReportLoader, Status, EventArguments, EventListener, EventNextHandler } from 'boost/lib/types'; | ||
@@ -421,0 +419,0 @@ } |
@@ -72,3 +72,3 @@ "use strict"; | ||
} | ||
_this.debug = _this.createDebugger('core'); | ||
_this.debugger = _this.createDebugger('core'); | ||
_this.console = new Console_1.default(new Reporter_1.default(), { | ||
@@ -93,2 +93,10 @@ footer: footer, | ||
}; | ||
Tool.prototype.debug = function (message) { | ||
var args = []; | ||
for (var _i = 1; _i < arguments.length; _i++) { | ||
args[_i - 1] = arguments[_i]; | ||
} | ||
this.debugger.apply(this, [message].concat(args)); | ||
return this; | ||
}; | ||
Tool.prototype.exit = function (message, code) { | ||
@@ -133,5 +141,5 @@ if (code === void 0) { code = 1; } | ||
if (arg === '--debug' || arg === '--silent') { | ||
var name = arg.slice(2); | ||
_this.config[name] = true; | ||
_this.console.options[name] = true; | ||
var name_1 = arg.slice(2); | ||
_this.config[name_1] = true; | ||
_this.console.options[name_1] = true; | ||
} | ||
@@ -138,0 +146,0 @@ }); |
{ | ||
"name": "boost", | ||
"version": "0.38.1", | ||
"version": "0.40.0", | ||
"description": "Robust pipeline for creating build tools that separate logic into routines and tasks.", | ||
@@ -58,3 +58,3 @@ "keywords": [], | ||
"devDependencies": { | ||
"@milesj/build-tool-config": "0.79.0", | ||
"@milesj/build-tool-config": "0.82.2", | ||
"@types/chalk": "^2.2.0", | ||
@@ -61,0 +61,0 @@ "@types/debug": "^0.0.30", |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
371250
1778