1
0
mirror of https://github.com/JuanCanham/HackMyResume.git synced 2025-07-11 04:31:07 +01:00

Move commands to Verb hierarchy

Move flat command functions (BUILD, ANALYZE, etc.) to a shallow Verb
hierarchy. Allow command verbs to inherit common functionality and prep
for better debugging/logging as well as test mocks.
This commit is contained in:
hacksalot
2016-01-09 06:44:22 -05:00
parent 47e8605f50
commit 88c71f6e9c
7 changed files with 90 additions and 14 deletions

View File

@ -165,7 +165,9 @@
function execVerb( src, dst, opts, log ) {
loadOptions.call( this, opts );
require('./core/error-handler').init( _opts.debug );
HMR.verbs[ this.name() ].call( null, src, dst, _opts, log );
var v = new HMR.verbs[ this.name() ]();
v.invoke.call( null, src, dst, _opts, log );
}