2017-01-18 00:58:09 +01:00
|
|
|
import * as q from 'smartq'
|
2016-10-02 20:35:13 +02:00
|
|
|
|
2016-10-21 17:48:52 +02:00
|
|
|
import * as paths from '../npmts.paths'
|
|
|
|
|
|
|
|
import * as plugins from './mod00.plugins'
|
2016-04-30 05:49:53 +02:00
|
|
|
|
2016-06-07 08:49:22 +02:00
|
|
|
export let run = function (configArg) {
|
2017-03-04 20:49:10 +00:00
|
|
|
let done = q.defer()
|
|
|
|
let config = configArg
|
2017-03-31 19:18:18 +02:00
|
|
|
plugins.beautylog.ora.text('now compiling ' + 'TypeScript')
|
2017-03-04 20:49:10 +00:00
|
|
|
plugins.tsn.compileGlobStringObject(config.ts, config.tsOptions, paths.cwd)
|
|
|
|
.then(() => {
|
|
|
|
plugins.beautylog.ok(`compiled the module's TypeScript!`)
|
|
|
|
done.resolve(config)
|
|
|
|
}).catch(err => { console.log(err) })
|
|
|
|
return done.promise
|
2016-09-06 17:21:25 +02:00
|
|
|
}
|