Я обнаружил странное поведение в Grunt, где кажется, что две задачи блокируют друг друга (или что-то в этом роде). Задачами являются: shell (https://github.com/sindresorhus/grunt-shell) и sass (https://github.com/gruntjs/grunt-contrib-sass).Задачи «блокировать» друг друга
My (reduced) Gruntfile;
"use strict";
var path = require('path');
module.exports = function(grunt) {
require('time-grunt')(grunt);
require('load-grunt-tasks')(grunt);
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
shell: {
options: {
stdout: true,
stderr: true
},
bower: {
command: path.resolve(process.cwd() + '/node_modules/.bin/bower --allow-root install')
}
},
/* ... other tasks */
sass: {
dist: {
options: {
trace: true
},
files: {
'dist/additional.css': 'assets/stylesheets/additional.scss'
}
}
}
});
grunt.registerTask('default', [
'shell',
'sass',
]);
}
Когда я начинаю grunt
моя задача оболочки закончена, но хрюкать «останавливается» на задачу оболочки:
Running "shell:bower" (shell) task
Running "sass:dist" (sass) task
### ctrl + C###
Execution Time (2015-04-06 10:56:14 UTC)
loading tasks 8.9s █ 1%
shell:bower 18.6s ██ 2%
sass:dist 13m 25.2s ██████████████████████████████████████████████ 97%
Total 13m 52.7s
Когда я начинаю эти задачи по отдельности (с grunt shell
соответственно grunt sass
) все работает отлично.
Любые идеи? Благодаря!
Можете ли вы предоставить свои зависимости, перечисленные на вашем пакете.json? – Rigotti
См. Https://gist.github.com/nehalist/bc0eb3fb5139c495fb46 – nehalist