forked from peortiz89/BCSR
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgruntfile.coffee
55 lines (48 loc) · 1.43 KB
/
gruntfile.coffee
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
module.exports = (grunt) ->
grunt.initConfig
pkg: grunt.file.readJSON('package.json')
svgmin:
bcsrIcons:
files: [{
expand: true
cwd: '_images/_grunticon'
src: ['**/*.svg']
dest: '_images/_grunticon'
}]
grunticon:
bcsrIcons:
files: [{
expand: true
cwd: '_images/_grunticon'
src: ['*.svg', '*.png']
dest: '_resources/css/icons'
}]
options:
loadersnippet: '../../../_js/grunticon.loader.js'
pngfolder: '../../../_images/why-simons-rock/at-a-glance/png-fallback-icons'
template: '_images/_grunticon/css.hbs'
enhanceSVG: true
customselectors:
"*": [".icon-$1--before:before", ".icon-$1--after:after"]
colors:
white: '#ffffff'
black: '#000000'
sass:
dist:
options:
style: 'compressed'
files:
'_css/app.css': '_css/app.scss'
watch:
styles:
files: ['_css/**/*.scss']
tasks: ['sass', 'autoprefixer']
options:
spawn: false
grunticon:
files: ['_images/_grunticon/*.svg', '_images/_grunticon/*.png']
tasks: ['svgmin:bcsrIcons', 'grunticon:bcsrIcons']
options:
spawn: false
require('load-grunt-tasks')(grunt)
grunt.registerTask('default', ['svgmin:bcsrIcons', 'grunticon:bcsrIcons', 'sass'])