tscoverage/dist/npmts.install.js

22 lines
876 B
JavaScript
Raw Permalink Normal View History

2016-03-12 09:21:16 +00:00
"use strict";
2016-05-25 03:23:48 +00:00
require("typings-global");
2016-03-12 09:21:16 +00:00
var plugins = require("./npmts.plugins");
var paths = require("./npmts.paths");
2016-05-17 00:32:40 +00:00
var npmts_promisechain_1 = require("./npmts.promisechain");
2016-03-12 09:21:16 +00:00
exports.run = function (configArg) {
var config = configArg;
var done = plugins.Q.defer();
/* -------------------------------------------------
* ----------- install typings ---------------
* ----------------------------------------------- */
npmts_promisechain_1.npmtsOra.text("now installing " + "typings".yellow);
2016-03-20 18:09:58 +00:00
var absoluteTypingsArray = plugins.smartpath.transform.toAbsolute(config.typings, paths.cwd);
2016-03-12 09:21:16 +00:00
plugins.gulp.src(absoluteTypingsArray)
.pipe(plugins.g.typings())
.pipe(plugins.g.gFunction(function () {
2016-05-17 00:32:40 +00:00
plugins.beautylog.ok("typings installed!");
2016-03-12 09:21:16 +00:00
done.resolve(config);
}, "atEnd"));
return done.promise;
};