2017-03-08 15:51:02 +00:00
|
|
|
import * as plugins from './smartshell.plugins'
|
|
|
|
import * as smartshellWrap from './smartshell.wrap'
|
|
|
|
|
|
|
|
export type TExecutor = 'sh' | 'bash'
|
|
|
|
|
|
|
|
export interface ISmartshellContructorOptions {
|
2017-03-10 19:14:40 +00:00
|
|
|
executor: TExecutor
|
|
|
|
sourceFilePaths: string[]
|
2017-03-08 15:51:02 +00:00
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
export class Smartshell {
|
2017-03-10 19:14:40 +00:00
|
|
|
sourceFiles: string[] = []
|
|
|
|
constructor (optionsArg: ISmartshellContructorOptions) {
|
|
|
|
for (let sourceFilePath of optionsArg.sourceFilePaths) {
|
|
|
|
this.sourceFiles.push(sourceFilePath)
|
2017-03-08 15:51:02 +00:00
|
|
|
}
|
2017-03-10 19:14:40 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
addSourceFiles(sourceFilePathsArray: string[]) {
|
|
|
|
for(let sourceFilePath of sourceFilePathsArray) {
|
|
|
|
this.sourceFiles.push(sourceFilePath)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
cleanSourceFiles () {
|
|
|
|
this.sourceFiles = []
|
|
|
|
}
|
2017-03-08 15:51:02 +00:00
|
|
|
}
|