CleverStack/cleverstack-cli

View on GitHub
lib/util/grunt.js

Summary

Maintainability
B
4 hrs
Test Coverage

Function runTasks has 55 lines of code (exceeds 25 allowed). Consider refactoring.
Open

exports.runTasks = function(projectFolder, modulePath) {
  return new Promise(function(resolve, reject) {
    var originalCwd = process.cwd();
    process.chdir(projectFolder);

Severity: Major
Found in lib/util/grunt.js - About 2 hrs to fix

    Function runTask has 37 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    function runTask(projectFolder, command) {
      var args       = [].slice.call(arguments, 1);
    
      return new Promise(function(resolve, reject) {
        var cmd      = !isWin ? 'grunt' : 'grunt.cmd'
    Severity: Minor
    Found in lib/util/grunt.js - About 1 hr to fix

      Function runDBMigrations has 31 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      function runDBMigrations(projectFolder) {
        lib.utils.warn('Running database migrations...');
      
        return new Promise(function(resolve, reject) {
          var env        = process.env
      Severity: Minor
      Found in lib/util/grunt.js - About 1 hr to fix

        There are no issues that match your filters.

        Category
        Status