Closed dead-claudia closed 8 years ago
Thanks @isiahmeadows, you are completely right! Check out #6 if you have a chance; I think both issues have been addressed.
I went with regular ShellJS commands like shelljs.rm
, shelljs.mkdir
, etc. instead of the packages you mentioned just because I am more familiar with ShellJS. If there is a compelling reason to use those other modules I'm happy to switch.
I also replaced all usage of execSync
with spawnSync
, since in every case spawnSync
was a better choice.
I noticed you're using
shx
, which might be helpful with npm-based build systems, but instead of usingshx rm -rf
,shx mkdir -p
,shx mv
, etc., you could userimraf.sync
,mkdirp.sync
,fs.renameSync
, etc. to avoid the extraexec
overhead. And if you need the ability to copy across partitions, ShellJS already uses an easy workaround.Oh, and just another suggestion, but take it or leave it: use
spawnSync
for thenpm
calls, so if someone usesniv 'package@1 package@2'
,npm
should error out, but does weird things instead.