davglass / cpr

Nodejs cp -R
Other
79 stars 80 forks source link

add a synchronous implementation #3

Closed stephenmathieson closed 7 years ago

stephenmathieson commented 11 years ago

for some reason, with all of the cp -r style modules out there, none of them have a sync version. i've added a simple synchronous implementation which allows for:

var cpr = require('cpr');

cpr.sync('/some/existing/dir', '/this/doesnt/exist/yet')

please note: i have not added support for any of your "options". just a synchronous cp -r.

stephenmathieson commented 11 years ago

also, your lint settings are extremely confusing:

npm test

> cpr@0.1.1 pretest /Users/stephenmathieson/cpr
> jshint --config ./node_modules/yui-lint/jshint.json ./lib/

lib/sync.js: line 26, col 10, 'sync' was used before it was defined.
lib/sync.js: line 26, col 9, 'sync' is defined but never used.

2 errors
npm ERR! weird error 1
npm ERR! not ok code 0
davglass commented 11 years ago

Thanks, this looks pretty good but I can't merge this until the API is exact between the two (the options need to work).

stephenmathieson commented 11 years ago

i understand. i don't know that i'll get around to adding options support today -- hopefully i'll have more open source time next week. should this go into a branch other than master for the time being?

davglass commented 11 years ago

We can leave it on this Pull Request for now, it's easy for anyone to install it from here if they need it. I can look into adding that support if you can't get to it (likely Monday tho)

stevenvachon commented 8 years ago

@davglass is this project dead?

davglass commented 8 years ago

Not dead, but that PR was abandoned and was never finished.