Tips &Tricks

0

TypeError: dest.on is not a function

Fol­low­ing is the anti pat­tern gulp.src( ‘Foo’ ).pipe( shell( ‘Bar’ ) ); Use the fol­low­ing pat­tern gulp.task( ‘Foo’, shell.task(‘Bar’) ); Anti-pattern Github Issue

0

Error in plugin ‘gulp-shell’

Fol­low­ing is the anti pat­tern gulp.src( ‘Foo’ ).pipe( shell( ‘Bar’ ) ); Use the fol­low­ing pat­tern gulp.task( ‘Foo’, shell.task(‘Bar’) ); Anti-pattern Github Issue

0

Call and retry last Allocation failed

Solu­tion: node –max–old-space-size=4096 <file­name> You need to tell node to over­write default heap size in v8. To see all the avail­able v8 flags run the fol­low­ing com­mand: node –v8-options –Fur­ther details on chromium bug

0

$? variable in linux

$? Sta­tus of the pre­vi­ous process / com­mand which ran on the shell $ pwd $ echo $? // returns 0 which means the pre­vi­ous com­mand ran sucess­fully $ blah­Com­mand $echo $? // returns 1…

0

path.join vs path.resolve in node.js

path.join([…paths]) joins all the path seg­ments using plat­form spe­cific delim­iter. path.join(‘/foo’, ‘bar’, ‘baz/zxcv’, ‘abcd’, ‘..’) // ‘/foo/bar/baz/zxcv/abcd/…’ path.resolve([…paths]) Resolves all the path seg­ments into an absolute path. It processes from right to left, until…