From 9d640786596f940caca7599dcbde8c89064246eb Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Mon, 2 Nov 2015 22:59:13 +0100 Subject: [PATCH] Clean grunt file --- Gruntfile.js | 116 +-------------------------------------------------- package.json | 11 ----- 2 files changed, 1 insertion(+), 126 deletions(-) diff --git a/Gruntfile.js b/Gruntfile.js index d83e60b3d..fa0c2026c 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -3,7 +3,6 @@ module.exports = function (grunt) { var paths = { dist: 'dist', - tmp: '.tmp', jade: 'views/**/**/*.jade', css: 'public/stylesheets/*.css', vendor: 'public/stylesheets/vendor', @@ -31,10 +30,6 @@ module.exports = function (grunt) { browserifyOptions: { 'debug': true }, watch: true } - }, - dist: { - src: [ paths.js ], - dest: paths.browserified } }, copy: { @@ -53,25 +48,8 @@ module.exports = function (grunt) { paths.browserified ] }] - }, - dist: { - files: [{ - dot: true, - src: [ - paths.tmp, - paths.browserified, - '<%= paths.dist %>/*', - '!<%= paths.dist %>/.git*' - ] - }] } }, - csslint: { - options: { - csslintrc: '.csslintrc' - }, - src: paths.css - }, express: { dev: { options: { @@ -82,95 +60,6 @@ module.exports = function (grunt) { debug: true, background: true } - }, - test: { - options: { - script: paths.server, - harmony: true, - port: 9000, - node_env: 'test', - background: true, - debug: false - } - }, - prod: { - options: { - script: paths.server, - harmony: true, - port: 9000, - node_env: 'production', - background: false, - debug: false - } - } - }, - filerev: { - options: { - copy: false - }, - dist: { - cwd: 'dist', - src: [ paths.js, paths.css, paths.img ], - dest: 'dist', - expand: true - } - }, - htmlmin: { - dist: { - options: { - removeComments: true, - collapseWhitespace: true - }, - files: [ { - expand: true, - src: [ '<%= paths.dist %>/views/**/**/*.html' ] - } ] - } - }, - imagemin: { - dist: { - files: [{ - expand: true, - cwd: './public/images', - src: '*.{png,jpg,jpeg}', - dest: '<%= paths.dist %>/public/images' - }] - } - }, - jade: { - dist: { - options: { - pretty: true - }, - files: [ { - src: '**/*.jade', - dest: '<%= paths.dist %>/views', - ext: '.html', - cwd: './views', - expand: true - } ] - } - }, - jshint: { - all: { - src: paths.js, - options: { - jshintrc: true - } - } - }, - usemin: { - html: [ '<%= paths.dist %>/views/**/**/*.html' ], - css: [ '<%= paths.dist %>/public/stylesheets/*.css' ], - options: { - assetsDirs: [ '<%= paths.dist %>/public' ] - } - }, - useminPrepare: { - html: '<%= paths.dist %>/views/index.html', - options: { - root: 'public', - dest: '<%= paths.dist %>/public' } }, watch: { @@ -220,15 +109,12 @@ module.exports = function (grunt) { ) }) - // TODO - // Build dist directory for production - // Clean build grunt.registerTask('clean', [], function () { grunt.loadNpmTasks('grunt-contrib-clean') grunt.task.run( - 'clean:dist' + 'clean:dev' ) }) } diff --git a/package.json b/package.json index 8693e9b0b..8ef7d1b9b 100644 --- a/package.json +++ b/package.json @@ -20,7 +20,6 @@ "compression": "^1.5.0", "config": "^1.14.0", "connect-livereload": "^0.5.3", - "cookie-parser": "^1.3.5", "debug": "^2.2.0", "dezalgo": "^1.0.3", "electron-spawn": "https://github.com/Chocobozzz/electron-spawn", @@ -29,20 +28,10 @@ "grunt": "^0.4.5", "grunt-browserify": "^4.0.1", "grunt-contrib-clean": "^0.6.0", - "grunt-contrib-concat": "^0.5.1", "grunt-contrib-copy": "0.8.0", - "grunt-contrib-csslint": "^0.4.0", - "grunt-contrib-cssmin": "^0.12.3", - "grunt-contrib-htmlmin": "^0.4.0", - "grunt-contrib-imagemin": "^0.9.4", - "grunt-contrib-jade": "^0.14.1", - "grunt-contrib-jshint": "^0.11.2", - "grunt-contrib-uglify": "^0.9.1", "grunt-contrib-watch": "^0.6.1", "grunt-express-server": "^0.5.1", - "grunt-filerev": "^2.3.1", "grunt-newer": "^1.1.1", - "grunt-usemin": "^3.0.0", "jade": "^1.10.0", "jquery": "^2.1.4", "js-yaml": "^3.3.1",