Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fs: add cp method #35880

Closed
cappp opened this issue Oct 30, 2020 · 1 comment
Closed

fs: add cp method #35880

cappp opened this issue Oct 30, 2020 · 1 comment
Labels
feature request Issues that request new features to be added to Node.js.

Comments

@cappp
Copy link

cappp commented Oct 30, 2020

Is your feature request related to a problem? Please describe.
Whenever I need to copy a directory to another destiny, I need to use an alternative library to do this.

Describe the solution you'd like
Add cp (Unix Name) method to fs, with the same utility of cp Unix, he can be like:

Parameters
src: PathLike
dest: PathLike
options: CpOptions

Describe alternatives you've considered
Library npc and fs-extra.

@iansu
Copy link
Contributor

iansu commented Oct 30, 2020

Thanks for the feature request! This is already being discussed by the Tooling Group (@nodejs/tooling).

The first step is producing an RFC that details exactly how the new cp method will work. Once we've completed that we'll be asking for input from the community. I'll share a link here when the RFC is ready so you and others can give your feedback.

@PoojaDurgad PoojaDurgad added the feature request Issues that request new features to be added to Node.js. label Dec 18, 2020
@bcoe bcoe mentioned this issue Aug 1, 2021
2 tasks
@bcoe bcoe closed this as completed in 87d6fd7 Aug 12, 2021
danielleadams pushed a commit that referenced this issue Aug 16, 2021
Introduces recursive cp method, based on fs-extra implementation.

PR-URL: #39372
Fixes: #35880
Refs: nodejs/tooling#98
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ian Sutherland <ian@iansutherland.ca>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request Issues that request new features to be added to Node.js.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants