From 7c03abd0a651eed6dd68c2853a6b40979ec42d8c Mon Sep 17 00:00:00 2001 From: Hristo Deshev Date: Tue, 17 Nov 2015 09:34:46 +0200 Subject: [PATCH] Prepare and build just the test app. Useful for test runs when you don't need everything below the apps folder. --- gruntfile.js | 58 ++++++++++++++++++++++++++++++---------------------- package.json | 1 + 2 files changed, 35 insertions(+), 24 deletions(-) diff --git a/gruntfile.js b/gruntfile.js index 5e56b9b00..dc15eca93 100644 --- a/gruntfile.js +++ b/gruntfile.js @@ -1,4 +1,5 @@ var tsconfig = require('./tsconfig.json'); +var shelljs = require("shelljs"); module.exports = function(grunt) { @@ -11,6 +12,12 @@ module.exports = function(grunt) { var fs=require("fs"); var pathModule=require("path"); + var tsLintOption = grunt.option('runtslint'); + var skipTsLint = tsLintOption == 'false' || tsLintOption == false; + if (tsLintOption == null) { + skipTsLint = false; + } + var filterTypeScriptFiles = function(content, srcPath) { var matchRule = /^.*@private/ig; if (matchRule.test(content)) @@ -109,19 +116,19 @@ module.exports = function(grunt) { }; var getSubDirs = function(dir) { - var allObjects = fs.readdirSync(dir); - var allDirs = []; - for (var i=0; i