From dda8cbac7c9335cedfd817593675e817606f7d8f Mon Sep 17 00:00:00 2001 From: Jordan Eldredge Date: Wed, 10 Dec 2014 19:57:42 -0800 Subject: [PATCH] Add grunt for production version --- .gitignore | 2 ++ Gruntfile.js | 45 +++++++++++++++++++++++++++++++++++++++++++++ index.html | 14 ++------------ jszip.2.4.0.min.js | 14 ++++++++++++++ package.json | 10 ++++++++++ 5 files changed, 73 insertions(+), 12 deletions(-) create mode 100644 Gruntfile.js create mode 100644 jszip.2.4.0.min.js create mode 100644 package.json diff --git a/.gitignore b/.gitignore index 5aaa8793..a5f86f57 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,3 @@ preview.png +production* +node_modules diff --git a/Gruntfile.js b/Gruntfile.js new file mode 100644 index 00000000..ff0ffd01 --- /dev/null +++ b/Gruntfile.js @@ -0,0 +1,45 @@ +module.exports = function(grunt) { + + // 1. All configuration goes here + grunt.initConfig({ + pkg: grunt.file.readJSON('package.json'), + + concat: { + dist: { + src: [ + "jszip.2.4.0.min.js", + "browser.js", + "file-manager.js", + "visualizer.js", + "media.js", + "font.js", + "skin.js", + "multi-display.js", + "hotkeys.js", + "winamp.js" + ], + dest: 'production.js', + } + }, + uglify: { + build: { + src: 'production.js', + dest: 'production.min.js' + } + }, + cssmin: { + combine: { + files: { + 'production.min.css': ['winamp.css'] + } + } + } + }); + + grunt.loadNpmTasks('grunt-contrib-concat'); + grunt.loadNpmTasks('grunt-contrib-uglify'); + grunt.loadNpmTasks('grunt-contrib-cssmin'); + + grunt.registerTask('default', ['concat', 'uglify', 'cssmin']); + +}; diff --git a/index.html b/index.html index 2d4933dd..7dd51ab9 100755 --- a/index.html +++ b/index.html @@ -10,7 +10,7 @@ - + @@ -89,17 +89,7 @@ - GitHub

- - - - - - - - - - - +