forked from phrase/angular-phrase
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathGruntfile.coffee
39 lines (31 loc) · 1017 Bytes
/
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
module.exports = (grunt) ->
require('load-grunt-tasks')(grunt)
grunt.loadNpmTasks('grunt-contrib-watch')
grunt.loadNpmTasks('grunt-contrib-coffee')
grunt.initConfig
pkg: grunt.file.readJSON('bower.json')
build_dir: 'dist'
coffee:
compile:
files:
'build/phrase.js': 'src/phrase.coffee'
'build/directives/phrase_javascript.js': 'src/directives/phrase_javascript.coffee'
'build/provider/phrase_javascript.js': 'src/provider/phrase_javascript.coffee'
concat:
core:
src: ['build/phrase.js', 'build/directives/phrase_javascript.js']
dest: '<%= build_dir %>/angular-phrase.js'
karma:
unit:
configFile: "karma.unit.conf.coffee"
singleRun: true
uglify:
core:
files:
'<%= build_dir %>/angular-phrase.min.js': '<%= concat.core.dest %>'
grunt.registerTask('default', ['karma'])
grunt.registerTask('build', [
'coffee:compile',
'concat:core',
'uglify:core',
])