Sails, grunt

I'm new to sails. I'm using:

  • sails@0.10.5
  • grunt-contrib-watch@0.5.3
  • grunt-contrib-jshint@0.10.0
  • jshint@2.5.11
  • I've been starting my server using either sails lift or sails lift --verbose . According to the sails documentation grunt default is ran. The first task is compileAssets . Which starts with jshint . My compileAssets tasks ends with a watch command.

    When a file is changed that is being watched, syncAssets is ran. syncAssets is identical to my compileAssets task. They both start with jshint .

    The problem is that while syncAssets is running, it is not reporting any jshint errors in the console, and/or stopping the syncAssets task so I have no idea if my code as compiled with out looking at the source.

    Then I must restart the server to find the error, since compileAssets will print the jshint error.

    Is something configured incorrectly in my tasks? Please help, this is significantly slowing down my workflow.

    tasks/register/default.js -- Unchanged

    module.exports = function (grunt) {
        grunt.registerTask('default', ['compileAssets', 'linkAssets',  'watch']);
    };
    

    tasks/register/syncAssets.js

    module.exports = function (grunt) {
        grunt.registerTask('syncAssets', [
        'jshint',
        'bower',
        'clean:dev',
        'copy:dev',
        'exec:compileTemplates',
        'exec:compilePartials',
        'compass'
        ]);
    };
    

    tasks/register/compileAssets.js module.exports = function (grunt) { grunt.registerTask('compileAssets', [ 'jshint', 'bower', 'clean:dev', 'copy:dev', 'exec:compileTemplates', 'exec:compilePartials', 'compass' ]); };

    链接地址: http://www.djcxy.com/p/78974.html

    上一篇: 部署authKey ftppass

    下一篇: 帆,咕噜声