From 3140f50f5aaf8041e525935c039e8a49ce2ed363 Mon Sep 17 00:00:00 2001 From: XhmikosR Date: Tue, 11 Mar 2014 10:00:14 +0200 Subject: [PATCH] Add "grunt-banner". We can't add a banner with "grunt-contrib-sass" anymore. --- Gruntfile.js | 21 ++++++++++++++++++--- package.json | 1 + 2 files changed, 19 insertions(+), 3 deletions(-) diff --git a/Gruntfile.js b/Gruntfile.js index c57b5b8..f81799a 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -24,10 +24,10 @@ module.exports = function (grunt) { // Metadata. meta: { - srcPath: 'sass/', distPath: 'dist/', + docsAssetsPath: 'docs/assets/', docsPath: 'docs/dist/', - docsAssetsPath: 'docs/assets/' + srcPath: 'sass/' }, banner: '/*!\n' + @@ -86,6 +86,21 @@ module.exports = function (grunt) { } }, + usebanner: { + dist: { + options: { + position: 'top', + banner: '<%= banner %>' + }, + files: { + src: [ + '<%= meta.distPath %>css/*.css', + '<%= meta.docsAssetsPath %>css/docs.css' + ] + } + } + }, + csscomb: { options: { config: 'sass/.csscomb.json' @@ -303,7 +318,7 @@ module.exports = function (grunt) { require('time-grunt')(grunt); // Default task(s). - grunt.registerTask('dist-css', ['sass', 'autoprefixer', 'csscomb', 'cssmin']); + grunt.registerTask('dist-css', ['sass', 'autoprefixer', 'usebanner', 'csscomb', 'cssmin']); grunt.registerTask('dist-js', ['concat', 'uglify']); grunt.registerTask('dist', ['clean', 'dist-css', 'dist-js', 'copy', 'build-ratchicons-data']); grunt.registerTask('validate-html', ['jekyll', 'validation']); diff --git a/package.json b/package.json index 2544813..1b726a2 100644 --- a/package.json +++ b/package.json @@ -28,6 +28,7 @@ "devDependencies": { "grunt": "~0.4.5", "grunt-autoprefixer": "~2.2.0", + "grunt-banner": "~0.3.1", "grunt-contrib-clean": "~0.6.0", "grunt-contrib-concat": "~0.5.0", "grunt-contrib-copy": "~0.7.0",