From a31c1776a4a4361aa84c87bc068d4bbb42a81b0e Mon Sep 17 00:00:00 2001 From: Vadim Makeev Date: Tue, 27 May 2014 13:02:58 +0200 Subject: [PATCH] New archive task for Grunt --- Gruntfile.js | 22 +++++++++++++++++++++- package.json | 1 + 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/Gruntfile.js b/Gruntfile.js index 4dae1f4..8acd709 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -82,6 +82,19 @@ module.exports = function(grunt) { }, src: ['**'] }, + compress: { + shower: { + options: { + archive: 'archive.zip' + }, + files: [{ + expand: true, + cwd: 'temp/pres/', + src: '**', + dest: '.' + }] + } + }, clean: ['temp'] }); @@ -92,4 +105,11 @@ module.exports = function(grunt) { 'clean' ]); -}; \ No newline at end of file + grunt.registerTask('archive', [ + 'copy', + 'replace', + 'compress', + 'clean' + ]); + +}; diff --git a/package.json b/package.json index 51c0c5f..a1ce2f9 100644 --- a/package.json +++ b/package.json @@ -34,6 +34,7 @@ "grunt": "^0.4.4", "grunt-bump": "0.0.13", "grunt-contrib-clean": "^0.5.0", + "grunt-contrib-compress": "^0.9.1", "grunt-contrib-copy": "^0.5.0", "grunt-gh-pages": "^0.9.1", "grunt-text-replace": "^0.3.11",