diff --git a/.gitignore b/.gitignore index 4b26396b..f562c278 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,5 @@ *.sublime-workspace node_modules build/ +openseadragon.zip +openseadragon.tar diff --git a/grunt.js b/grunt.js index cfc199b1..6d57fc51 100644 --- a/grunt.js +++ b/grunt.js @@ -1,5 +1,7 @@ module.exports = function(grunt) { - + + grunt.loadNpmTasks("grunt-contrib-compress"); + var distribution = "build/openseadragon.js", minified = "build/openseadragon.min.js", sources = [ @@ -50,6 +52,18 @@ module.exports = function(grunt) { dest: minified } }, + compress: { + zip: { + files: { + "openseadragon.zip": "build/**" + } + }, + tar: { + files: { + "openseadragon.tar": "build/**" + } + } + }, qunit: { all: [ "http://localhost:8000/test/test.html" ] }, @@ -99,4 +113,6 @@ module.exports = function(grunt) { // Test task. grunt.registerTask("test", "default server qunit"); + // Package task. + grunt.registerTask("package", "default compress"); }; diff --git a/package.json b/package.json index 0195b2a7..1df4ea7d 100644 --- a/package.json +++ b/package.json @@ -5,7 +5,8 @@ "dependencies": { "grunt": "0.3.17", "qunitjs": "1.11.0", - "phantomjs": "1.8.1-3" + "phantomjs": "1.8.1-3", + "grunt-contrib-compress": "0.3.3" }, "scripts": { "test": "grunt test"