-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathGruntfile.js
41 lines (32 loc) · 1.25 KB
/
Gruntfile.js
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
module.exports = function (grunt) {
var path = require('path');
var fs = require('fs');
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-ts');
grunt.loadNpmTasks('grunt-contrib-copy');
grunt.loadNpmTasks('grunt-contrib-clean');
grunt.loadNpmTasks('grunt-protractor-runner');
grunt.loadNpmTasks('grunt-contrib-cssmin');
grunt.loadNpmTasks('grunt-sass');
grunt.loadNpmTasks('grunt-contrib-csslint');
grunt.config.init(grunt.file.readJSON('./config/grunt.config.json'));
grunt.task.loadTasks('grunt-tasks');
var configureMiddleware = require('./grunt-modules/configureMiddleware');
configureMiddleware(grunt, 'connect', null, 'test/views/index.jade');
grunt.event.once('connect.examples.listening', function(host, port) {
var url = 'http://localhost:' + port + '/examples/index.html';
require('open')(url);
});
grunt.registerTask('ts-build', ['clean:build', 'wrap-jade', 'ts:build', 'clean:post-build']);
grunt.registerTask('build', [
'ts-build',
'wrap-module',
'uglify',
'sass',
'csslint',
'cssmin',
'copy:interfaces',
'ts:tests'
]);
grunt.registerTask('view', ['connect:keepalive']);
};