update indention
This commit is contained in:
parent
66f2321d99
commit
d821a2efa6
@ -8,27 +8,27 @@ import { INpmtsConfig } from './npmts.config'
|
||||
|
||||
let npmtsSmartchok: smartchok.Smartchok = null
|
||||
export let run = (configArg: INpmtsConfig) => {
|
||||
let done = q.defer()
|
||||
if (configArg.watch && npmtsSmartchok === null) {
|
||||
let pathsToWatch: string[] = []
|
||||
for (let key in configArg.ts) {
|
||||
pathsToWatch.push(key)
|
||||
}
|
||||
for (let key in configArg.testTs) {
|
||||
pathsToWatch.push(key)
|
||||
}
|
||||
npmtsSmartchok = new smartchok.Smartchok(pathsToWatch)
|
||||
npmtsSmartchok.getObservableFor('change').then((changeObservableArg) => {
|
||||
plugins.beautylog.info('now watching...')
|
||||
changeObservableArg.subscribe(() => {
|
||||
cli.run()
|
||||
})
|
||||
})
|
||||
npmtsSmartchok.start()
|
||||
done.resolve(configArg)
|
||||
} else {
|
||||
plugins.beautylog.info('not watching')
|
||||
done.resolve(configArg)
|
||||
let done = q.defer()
|
||||
if (configArg.watch && npmtsSmartchok === null) {
|
||||
let pathsToWatch: string[] = []
|
||||
for (let key in configArg.ts) {
|
||||
pathsToWatch.push(key)
|
||||
}
|
||||
return done.promise
|
||||
for (let key in configArg.testTs) {
|
||||
pathsToWatch.push(key)
|
||||
}
|
||||
npmtsSmartchok = new smartchok.Smartchok(pathsToWatch)
|
||||
npmtsSmartchok.getObservableFor('change').then((changeObservableArg) => {
|
||||
plugins.beautylog.info('now watching...')
|
||||
changeObservableArg.subscribe(() => {
|
||||
cli.run()
|
||||
})
|
||||
})
|
||||
npmtsSmartchok.start()
|
||||
done.resolve(configArg)
|
||||
} else {
|
||||
plugins.beautylog.info('not watching')
|
||||
done.resolve(configArg)
|
||||
}
|
||||
return done.promise
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user