How to overwrite the file gulp'ohms?

Need to optimize and store svg in the source code.
Plan to use gulp-svgmin
gulp.task('svg-minify', function () {
 return gulp.src('logo.svg')
.pipe(svgmin())
.pipe(gulp.dest('logo.svg'));
});

The problem is that if you try to write to the same file, node crashes with an error.
``
Error: EEXIST: file already exists, mkdir '/home/khvostov/app/logo.svg'
``

Please tell me how to do?
July 4th 19 at 22:59
1 answer
July 4th 19 at 23:01
Solution
stackoverflow.com/questions/22418799/can-gulp-over...

gulp.task('svg-minify', function () {
return gulp.src('logo.svg')
.pipe(svgmin())
.pipe(gulp.dest('./'));
});

Find more questions by tags Gulp.jsNode.jsSVG