Switch to "serve" verb.
The grunt community has moved to using verbs consistently in their task names, so "server" has been renamed "serve"; getting it wrong results in a bizarro error, so this is slightly nicer for newcomers to the project with history in other grunt projects. Change-Id: If1266371d0e548e71f579e440ba7d4e7db07918f
This commit is contained in:
parent
05101c200d
commit
58d82435d2
15
Gruntfile.js
15
Gruntfile.js
@ -596,7 +596,7 @@ module.exports = function (grunt) {
|
|||||||
* source in a local web server. It does no watching, it simply hosts the
|
* source in a local web server. It does no watching, it simply hosts the
|
||||||
* files.
|
* files.
|
||||||
*/
|
*/
|
||||||
grunt.registerTask('server:dist', [
|
grunt.registerTask('serve:dist', [
|
||||||
'clean',
|
'clean',
|
||||||
'compile',
|
'compile',
|
||||||
'package',
|
'package',
|
||||||
@ -610,7 +610,7 @@ module.exports = function (grunt) {
|
|||||||
* will automatically lint, test, and refresh
|
* will automatically lint, test, and refresh
|
||||||
* the code when a change is detected.
|
* the code when a change is detected.
|
||||||
*/
|
*/
|
||||||
grunt.registerTask('server', [
|
grunt.registerTask('serve', [
|
||||||
'clean',
|
'clean',
|
||||||
'compile',
|
'compile',
|
||||||
'configureProxies:livereload',
|
'configureProxies:livereload',
|
||||||
@ -619,6 +619,17 @@ module.exports = function (grunt) {
|
|||||||
'watch'
|
'watch'
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Support the old non-verb form of invoking `serve` but warn.
|
||||||
|
*/
|
||||||
|
grunt.registerTask('server',
|
||||||
|
'DEPRECATED TASK. Use the "serve" task instead',
|
||||||
|
function (target) {
|
||||||
|
grunt.log.warn('The `server` task has been deprecated. Use ' +
|
||||||
|
'`grunt serve` to start a server.');
|
||||||
|
grunt.task.run(['serve:' + target]);
|
||||||
|
});
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* grunt test:integration
|
* grunt test:integration
|
||||||
*
|
*
|
||||||
|
Loading…
x
Reference in New Issue
Block a user