From b8a9190647bdc0e16f794058e8f687c17dacdf17 Mon Sep 17 00:00:00 2001 From: DamianEdwards Date: Wed, 21 May 2014 22:41:06 -0700 Subject: [PATCH] Remove grunt tasks as they'll come from core tasks --- makefile.shade | 50 +------------------------------------------------- 1 file changed, 1 insertion(+), 49 deletions(-) diff --git a/makefile.shade b/makefile.shade index 50e343e22c..cae07ce477 100644 --- a/makefile.shade +++ b/makefile.shade @@ -5,52 +5,4 @@ var FULL_VERSION='0.1' var AUTHORS='Microsoft' use-standard-lifecycle -k-standard-goals - -#install-node - var binDir = '${Path.Combine(Directory.GetCurrentDirectory(), "bin")}' - var nodeDir = '${Path.Combine(binDir, "node")}' - - -// Check if node is already installed locally - var nodeVer = '0.10.28' - var nodeMsi = 'node-v${nodeVer}-x86.msi' - var nodeUrl = 'http://nodejs.org/dist/v${nodeVer}/${nodeMsi}' - var nodeMsiPath = '${Path.Combine(binDir, nodeMsi)}' - var nodeInstalled = '${Directory.Exists(nodeDir)}' - @{ - Directory.CreateDirectory(nodeDir); - if (!nodeInstalled) { - // Download node installer msi - var wc = new WebClient(); - wc.DownloadFile(nodeUrl, nodeMsiPath); - } - } - - -// Extract it to local dir using msiexec: - exec program='msiexec' commandline='/a ${nodeMsiPath} /qb TARGETDIR=${nodeDir}' if='!nodeInstalled' - -#restore-npm-modules .install-node - @{ - // Find all dirs that contain a package.json file that aren't installed node modules - var currentDir = Directory.GetCurrentDirectory(); - var npmCmd = Path.Combine(currentDir, "bin\\node\\nodejs\\npm.cmd"); - var npmDirs = Directory.GetFiles(currentDir, "package.json", SearchOption.AllDirectories) - .Where(p => p.IndexOf(Path.DirectorySeparatorChar + "node_modules" + Path.DirectorySeparatorChar) < 0) - .Select(p => Path.GetDirectoryName(p)) - .Distinct(); - } - - exec program='${npmCmd}' commandline='install' workingdir='${dir}' each='var dir in npmDirs' - -#run-grunt .restore-npm-modules target='compile' - @{ - // Find all dirs that contain a gruntfile.js file - var currentDir = Directory.GetCurrentDirectory(); - var nodeExe = Path.Combine(currentDir, "bin\\node\\nodejs\\node.exe"); - var gruntDirs = Directory.GetFiles(currentDir, "gruntfile.js", SearchOption.AllDirectories) - .Where(p => p.IndexOf(Path.DirectorySeparatorChar + "node_modules" + Path.DirectorySeparatorChar) < 0) - .Select(p => Path.GetDirectoryName(p)) - .Distinct(); - } - - exec program='${nodeExe}' commandline='node_modules\\grunt-cli\\bin\\grunt' workingdir='${dir}' each='var dir in gruntDirs' \ No newline at end of file +k-standard-goals \ No newline at end of file