From 6c4643d4472b0d474a5436fc8f3e904af84f12e4 Mon Sep 17 00:00:00 2001 From: Ian Gilman Date: Mon, 25 Mar 2013 10:02:41 -0700 Subject: [PATCH] Grunt publish now publishes into the new folder in site-build --- Gruntfile.js | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/Gruntfile.js b/Gruntfile.js index eef1363b..e20b5e7c 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -14,6 +14,7 @@ module.exports = function(grunt) { // ---------- var distribution = "build/openseadragon/openseadragon.js", minified = "build/openseadragon/openseadragon.min.js", + releaseRoot = "../site-build/built-openseadragon/", sources = [ "src/openseadragon.js", "src/fullscreen.js", @@ -52,11 +53,7 @@ module.exports = function(grunt) { clean: { build: ["build"], release: { - src: [ - "../site-build/openseadragon", - "../site-build/openseadragon.zip", - "../site-build/openseadragon.tar" - ], + src: [releaseRoot], options: { force: true } @@ -155,10 +152,10 @@ module.exports = function(grunt) { // ---------- // Copy:release task. - // Copies the contents of the build folder into ../site-build. + // Copies the contents of the build folder into the release folder. grunt.registerTask("copy:release", function() { grunt.file.recurse("build", function(abspath, rootdir, subdir, filename) { - var dest = "../site-build/" + var dest = releaseRoot + (subdir ? subdir + "/" : '/') + filename; @@ -185,7 +182,7 @@ module.exports = function(grunt) { // ---------- // Publish task. - // Cleans the built files out of ../site-build and copies newly built ones over. + // Cleans the built files out of the release folder and copies newly built ones over. grunt.registerTask("publish", ["package", "clean:release", "copy:release"]); // ----------