2016-11-24 22:21:40 +00:00
|
|
|
import * as plugins from './npmci.plugins'
|
|
|
|
import {bash} from './npmci.bash'
|
|
|
|
import * as env from './npmci.env'
|
|
|
|
import * as buildDocker from './npmci.build.docker'
|
2016-06-02 11:39:03 +00:00
|
|
|
|
2016-09-04 14:05:47 +00:00
|
|
|
/**
|
|
|
|
* defines possible build services
|
|
|
|
*/
|
2016-11-24 22:21:40 +00:00
|
|
|
export type TBuildService = 'docker';
|
2016-09-04 14:05:47 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* builds for a specific service
|
|
|
|
*/
|
2016-11-24 22:21:40 +00:00
|
|
|
export let build = function(commandArg): plugins.q.Promise<any> {
|
|
|
|
switch (commandArg) {
|
|
|
|
case 'docker':
|
|
|
|
return buildDocker.build()
|
2016-06-05 04:26:05 +00:00
|
|
|
default:
|
2016-11-24 22:21:40 +00:00
|
|
|
plugins.beautylog.log('build target ' + commandArg + ' not recognised!')
|
2016-09-04 14:05:47 +00:00
|
|
|
};
|
2016-11-24 22:21:40 +00:00
|
|
|
return
|
2016-06-03 00:10:34 +00:00
|
|
|
}
|