diff --git a/index.d.ts b/index.d.ts
index 3456ecf..20843f8 100644
--- a/index.d.ts
+++ b/index.d.ts
@@ -4,6 +4,7 @@ declare module NpmtsPlugins {
beautylog: any;
gulp: any;
g: {
+ if: any;
insert: any;
sequence: any;
tsd: any;
@@ -17,6 +18,9 @@ declare module NpmtsPlugins {
declare module NpmtsPaths {
var init: () => any;
}
+declare module NpmtsInfo {
+ var init: () => void;
+}
declare module NpmtsDefault {
var init: () => void;
}
@@ -24,6 +28,7 @@ declare var plugins: {
beautylog: any;
gulp: any;
g: {
+ if: any;
insert: any;
sequence: any;
tsd: any;
diff --git a/index.js b/index.js
index 3b4da3c..004b108 100644
--- a/index.js
+++ b/index.js
@@ -8,6 +8,7 @@ var NpmtsPlugins;
beautylog: require("beautylog"),
gulp: require("gulp"),
g: {
+ if: require("gulp-if"),
insert: require("gulp-insert"),
sequence: require("gulp-sequence"),
tsd: require("gulp-tsd"),
@@ -33,6 +34,19 @@ var NpmtsPaths;
return paths;
};
})(NpmtsPaths || (NpmtsPaths = {}));
+///
+var NpmtsInfo;
+(function (NpmtsInfo) {
+ NpmtsInfo.init = function () {
+ if (process.env.TRAVIS) {
+ plugins.beautylog.warn("We are on TRAVIS. Typings will not be installed due to GitHub API restrictions.");
+ plugins.beautylog.log("Make sure the repo tracks ting directories");
+ }
+ else {
+ plugins.beautylog.log("We are on a dev machine. Typings will be installed prior to TypeScript compilation.");
+ }
+ };
+})(NpmtsInfo || (NpmtsInfo = {}));
///
///
var NpmtsDefault;
@@ -40,10 +54,10 @@ var NpmtsDefault;
NpmtsDefault.init = function () {
plugins.gulp.task("defaultTsd", function (cb) {
plugins.beautylog.log("now installing typings from" + " ts/tsd.json".blue);
- plugins.g.tsd({
+ plugins.g.if(process.env.TRAVIS, plugins.g.tsd({
command: 'reinstall',
config: paths.tsd
- }, cb);
+ }, cb));
});
plugins.gulp.task("defaultIndexTS", function () {
plugins.beautylog.log("now compiling" + " ts/index.ts".blue);
@@ -81,8 +95,10 @@ var NpmtsDefault;
///
///
///
+///
///
///
var plugins = NpmtsPlugins.init();
var paths = NpmtsPaths.init();
+NpmtsInfo.init();
NpmtsDefault.init();
diff --git a/package.json b/package.json
index c6378c1..a9f327c 100644
--- a/package.json
+++ b/package.json
@@ -29,6 +29,7 @@
"dependencies": {
"beautylog": "2.0.2",
"gulp": "3.9.0",
+ "gulp-if": "^2.0.0",
"gulp-insert": "0.5.0",
"gulp-sequence": "^0.4.4",
"gulp-tsd": "^0.1.0",
diff --git a/ts/index.ts b/ts/index.ts
index f05b2ae..a4dd2df 100644
--- a/ts/index.ts
+++ b/ts/index.ts
@@ -2,9 +2,11 @@
///
///
///
+///
///
///
var plugins = NpmtsPlugins.init();
var paths = NpmtsPaths.init();
+NpmtsInfo.init();
NpmtsDefault.init();
diff --git a/ts/npmts.default.ts b/ts/npmts.default.ts
index d227742..eabd304 100644
--- a/ts/npmts.default.ts
+++ b/ts/npmts.default.ts
@@ -4,10 +4,13 @@ module NpmtsDefault {
export var init = function() {
plugins.gulp.task("defaultTsd",function(cb){
plugins.beautylog.log("now installing typings from" + " ts/tsd.json".blue);
- plugins.g.tsd({
- command: 'reinstall',
- config: paths.tsd
- }, cb);
+ plugins.g.if(process.env.TRAVIS,
+ plugins.g.tsd({
+ command: 'reinstall',
+ config: paths.tsd
+ }, cb)
+ )
+ ;
});
diff --git a/ts/npmts.info.ts b/ts/npmts.info.ts
new file mode 100644
index 0000000..aa09455
--- /dev/null
+++ b/ts/npmts.info.ts
@@ -0,0 +1,12 @@
+///
+
+module NpmtsInfo {
+ export var init = function(){
+ if(process.env.TRAVIS){
+ plugins.beautylog.warn("We are on TRAVIS. Typings will not be installed due to GitHub API restrictions.");
+ plugins.beautylog.log("Make sure the repo tracks ting directories")
+ } else {
+ plugins.beautylog.log("We are on a dev machine. Typings will be installed prior to TypeScript compilation.");
+ }
+ }
+}
diff --git a/ts/npmts.plugins.ts b/ts/npmts.plugins.ts
index 2ee6713..be19d40 100644
--- a/ts/npmts.plugins.ts
+++ b/ts/npmts.plugins.ts
@@ -5,6 +5,7 @@ module NpmtsPlugins {
beautylog: require("beautylog"),
gulp: require("gulp"),
g: {
+ if: require("gulp-if"),
insert: require("gulp-insert"),
sequence: require("gulp-sequence"),
tsd: require("gulp-tsd"),