Closed dankeder closed 8 years ago
This also causes crashes when gulp is run from within an IDE that is piping the output from stdout. I agree this should be removed.
Seems project is abandoned ;)
Yeah it does seems abandoned. If you add option silent it skips the issue. I know it is not the proper fix, but at least I was able to get around this issue.
rsync({
...
silent: true,
...
});
This is fix the problem
process.stdout.write(util.format.apply(this, arguments) + "\r\r");
'use strict';
var gutil = require('gulp-util');
var util = require('util');
function log() {
process.stdout.write(util.format.apply(this, arguments) + "\r\r");
}
module.exports = function() {
// HACK: In order to show rsync's transfer progress, override `console` temporarily...
var orig = console.log;
console.log = log;
var retval = gutil.log.apply(this, arguments);
console.log = orig;
return retval;
};
thanks @alansouzati, this worked
gulp-rsync crashes when it's output is redirected to a file:
I believe it should never ever call
process.stdout.cursorTo(0)
. Removing that line helps, as well as addingsilent: true
to arguments.