Created
December 15, 2014 12:58
-
-
Save rjmacarthy/20548f680267e15ce3f9 to your computer and use it in GitHub Desktop.
Grunt File SASS
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module.exports = function(grunt) { | |
grunt.initConfig({ | |
sass: { | |
dist: { | |
options: { | |
includePaths: require('node-bourbon').includePaths, | |
includePaths: require('node-neat').includePaths | |
}, | |
files: { | |
'public/css/style.css': 'public/scss/style.scss' | |
} | |
} | |
}, | |
watch: { | |
css: { | |
files: ['**/*.scss'], | |
tasks: ['sass', 'concat', 'cssmin'] | |
}, | |
js: { | |
files: ['public/js/*.js'], | |
tasks: ['concat', 'uglify', 'jshint'] | |
} | |
}, | |
harp: { | |
server: { | |
server: true, | |
port: 9000 | |
}, | |
dist: {} | |
}, | |
jshint: { | |
all: { | |
src: 'public/js/main.js' | |
} | |
}, | |
concat: { | |
js: { | |
src: 'public/js/*.js', | |
dest: 'public/dist/main.js' | |
}, | |
css: { | |
src: 'public/css/*.css', | |
dest: 'public/dist/main.css' | |
} | |
}, | |
uglify: { | |
dist: { | |
src: 'public/dist/main.js', | |
dest: 'public/dist/main.min.js' | |
} | |
}, | |
cssmin: { | |
css: { | |
src: 'public/dist/main.css', | |
dest: 'public/dist/main.min.css' | |
} | |
}, | |
concurrent: { | |
default: ['harp', 'watch', 'jshint'], | |
options: { | |
logConcurrentOutput: true, | |
limit: 4 | |
} | |
} | |
}); | |
require('load-grunt-tasks')(grunt); | |
grunt.registerTask('default', ['sass', 'concat', 'uglify', 'cssmin', 'concurrent:default']) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment