Created
September 8, 2015 02:04
-
-
Save jerrylau91/58414ddb12d8c594fb93 to your computer and use it in GitHub Desktop.
Grunt file for compiling sass
This file contains hidden or 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
'use strict'; | |
/* | |
* Node Module | |
*/ | |
module.exports = function(grunt) { | |
// Task configuration | |
grunt.initConfig({ | |
/** | |
* Get package meta data | |
*/ | |
pkg: grunt.file.readJSON('package.json'), | |
/** | |
* Sass | |
*/ | |
sass: { | |
dist: { | |
options: { | |
sourcemap: 'auto', | |
style: 'compressed', | |
noCache: true | |
}, | |
files: { | |
'resources/css/style.css': 'resources/sass/PPP.scss' | |
} | |
} | |
}, | |
/* | |
* Watch | |
*/ | |
watch: { | |
sass: { | |
files: ['resources/sass/**/*.{scss,sass}'], | |
tasks: ['sass:dist'] | |
} | |
} | |
}); | |
/* | |
* Load Grunt Dependencies | |
*/ | |
grunt.loadNpmTasks('grunt-contrib-sass'); | |
grunt.loadNpmTasks('grunt-contrib-watch'); | |
/* | |
* Default Task | |
*/ | |
grunt.registerTask('default', ['sass:dist', 'watch']); | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment