From 6c4d6bda843b733f852f656fd87a015bf6c653ee Mon Sep 17 00:00:00 2001 From: Vit Brunner Date: Wed, 29 Oct 2014 12:10:21 +0100 Subject: [PATCH] Reorder things --- Gruntfile.coffee | 128 +++++++++++++++++++++++------------------------ bower.json | 6 +-- package.json | 14 +++--- 3 files changed, 74 insertions(+), 74 deletions(-) diff --git a/Gruntfile.coffee b/Gruntfile.coffee index 5eb0ff4..978ddfe 100644 --- a/Gruntfile.coffee +++ b/Gruntfile.coffee @@ -7,6 +7,16 @@ module.exports = (grunt) -> destination: 'build' } + coffee: { + main: { + expand: true + cwd: '<%= var.source %>' + src: '**/*.coffee' + dest: '<%= var.destination %>' + ext: '.js' + } + } + connect: { server: { options: { @@ -15,47 +25,6 @@ module.exports = (grunt) -> } } - watch: { - main: { - files: '<%= var.source %>/**/*' - tasks: ['default', 'qunit'] - } - min: { - files: [ - '<%= var.destination %>/scripts/**/*.js' - '<%= var.destination %>/bower_components/**/*.js' - ] - tasks: ['uglify'] - } - } - - uglify: { - main: { - files: { - 'build/min/scripts.js': [ - 'build/bower_components/lodash/dist/lodash.js' - 'build/bower_components/angular/angular.js' - 'build/bower_components/angular-route/angular-route.js' - 'build/bower_components/angular-sanitize/angular-sanitize.js' - 'build/bower_components/marked/lib/marked.js' - 'build/scripts/**/*.js' - ] - } - } - } - - cssmin: { - main: { - files: { - 'build/min/styles.css': [ - 'build/bower_components/fontawesome/css/font-awesome.min.css' - 'build/bower_components/pure/pure-min.css' - 'build/styles/**/*.css' - ] - } - } - } - copy: { main: { expand: true @@ -65,23 +34,15 @@ module.exports = (grunt) -> } } - coffee: { + cssmin: { main: { - expand: true - cwd: '<%= var.source %>' - src: '**/*.coffee' - dest: '<%= var.destination %>' - ext: '.js' - } - } - - stylus: { - main: { - expand: true - cwd: '<%= var.source %>' - src: '**/*.styl' - dest: '<%= var.destination %>' - ext: '.css' + files: { + 'build/min/styles.css': [ + 'build/bower_components/fontawesome/css/font-awesome.min.css' + 'build/bower_components/pure/pure-min.css' + 'build/styles/**/*.css' + ] + } } } @@ -102,17 +63,56 @@ module.exports = (grunt) -> } } } + + stylus: { + main: { + expand: true + cwd: '<%= var.source %>' + src: '**/*.styl' + dest: '<%= var.destination %>' + ext: '.css' + } + } + + uglify: { + main: { + files: { + 'build/min/scripts.js': [ + 'build/bower_components/lodash/dist/lodash.js' + 'build/bower_components/angular/angular.js' + 'build/bower_components/angular-route/angular-route.js' + 'build/bower_components/angular-sanitize/angular-sanitize.js' + 'build/bower_components/marked/lib/marked.js' + 'build/scripts/**/*.js' + ] + } + } + } + + watch: { + main: { + files: '<%= var.source %>/**/*' + tasks: ['default', 'qunit'] + } + min: { + files: [ + '<%= var.destination %>/scripts/**/*.js' + '<%= var.destination %>/bower_components/**/*.js' + ] + tasks: ['uglify'] + } + } } - grunt.loadNpmTasks('grunt-contrib-connect'); - grunt.loadNpmTasks('grunt-contrib-watch'); - grunt.loadNpmTasks('grunt-contrib-uglify'); - grunt.loadNpmTasks('grunt-contrib-cssmin'); - grunt.loadNpmTasks('grunt-contrib-copy'); grunt.loadNpmTasks('grunt-contrib-coffee'); - grunt.loadNpmTasks('grunt-contrib-stylus'); + grunt.loadNpmTasks('grunt-contrib-connect'); + grunt.loadNpmTasks('grunt-contrib-copy'); + grunt.loadNpmTasks('grunt-contrib-cssmin'); grunt.loadNpmTasks('grunt-contrib-jade'); - grunt.loadNpmTasks("grunt-contrib-qunit"); + grunt.loadNpmTasks('grunt-contrib-qunit'); + grunt.loadNpmTasks('grunt-contrib-stylus'); + grunt.loadNpmTasks('grunt-contrib-uglify'); + grunt.loadNpmTasks('grunt-contrib-watch'); grunt.registerTask 'default', [ 'copy', 'coffee', 'stylus', 'jade' ] grunt.registerTask 'serve', [ 'default', 'connect', 'watch' ] diff --git a/bower.json b/bower.json index 724225e..568038a 100644 --- a/bower.json +++ b/bower.json @@ -3,14 +3,14 @@ "version": "0.0.1", "author": "Vit Brunner", "dependencies": { - "lodash": "2.4.1", "angular": "1.2.20", "angular-route": "1.2.20", "angular-sanitize": "1.2.20", + "fontawesome": "3.0.2", + "lodash": "2.4.1", "marked": "0.3.2", "pure": "0.2.0", - "qunit": "1.13.x", - "fontawesome": "3.0.2" + "qunit": "1.13.x" }, "license": "MIT" } diff --git a/package.json b/package.json index e9c51e3..92cb9f4 100644 --- a/package.json +++ b/package.json @@ -7,15 +7,15 @@ "bower": "1.3.x", "grunt": "0.4.x", "grunt-cli": "0.1.x", - "grunt-contrib-connect": "0.8.x", - "grunt-contrib-watch": "0.6.x", - "grunt-contrib-uglify": "0.6.x", - "grunt-contrib-cssmin": "0.10.x", - "grunt-contrib-copy": "0.7.x", "grunt-contrib-coffee": "0.12.x", - "grunt-contrib-stylus": "0.20.x", + "grunt-contrib-connect": "0.8.x", + "grunt-contrib-copy": "0.7.x", + "grunt-contrib-cssmin": "0.10.x", "grunt-contrib-jade": "0.13.x", - "grunt-contrib-qunit": "0.5.x" + "grunt-contrib-qunit": "0.5.x", + "grunt-contrib-stylus": "0.20.x", + "grunt-contrib-uglify": "0.6.x", + "grunt-contrib-watch": "0.6.x" }, "scripts": { "test": "node_modules/.bin/grunt test",