As shown below, if I do cp -r a b with shelljs where a is a directory and b doesn't exist, shelljs creates b/a directories and the copies the contents of a into b/a. Instead, like in a unix shell, it should create b directory and copy the contents of a into b.
> mkdir a
> touch a/file.txt
> node
> require('shelljs/global')
{}
> cp('-r', 'a', 'b');
undefined
>
(To exit, press ^C again or type .exit)
>
> ls b/
a
> rm -rvf b
b/a/file.txt
b/a
b/
> cp -rvp a b
a -> b
a/file.txt -> b/file.txt