Repository navigation
Replies: 3 comments 1 reply
|
Hi @N7ghtm4r3, thanks for this one too! This fits well with #666: once we have /**
* Copies this file or directory tree to [target], which becomes the new root.
* Fails on the first error, leaving [target] partially copied.
* Symbolic links are skipped. Not available on web.
*/
public suspend fun PlatformFile.copyRecursively(
target: PlatformFile,
overwrite: Boolean = false,
)Which would give: source.copyRecursively(target) // source/a.txt -> target/a.txt
source.copyRecursively(target, overwrite = true) // merge into an existing target
file.copyRecursively(target) // also works on a regular fileDesign points:
Platform notes:
What's your concrete use case? Does this API cover it, or would you change anything (target semantics, overwrite behavior, naming, etc.)? Once we agree, feel free to open a PR after #666, with tests for each platform. |
|
Hi @vinceglb! As the comment on discussion about Additional I would implement also callbacks like Let me know if you agree with that and I am very Happy about integrate It ASAP! |
|
Hi @vinceglb! I just opened the related PR for this integration, the PR is the #677! |
Uh oh!
There was an error while loading. Please reload this page.
Hi @vinceglb!
Could be very useful to introduce an
APIlike copy-recursively to copy recursively all files in a folder in batch to other destination in each targets.If for you could be good to have I can handle this integration!
All reactions