Commit efc9a3c
Roman Inflianskas
stdlib/os: Add options argument to copy functions
Sometimes there is a need to copy symlinks as they are. This commit adds
optional argument `options` to all copy functions in `os` module.
`options` argument is an object for easier modification in the future.
Also, bugs in `copyDir`, `copyDirWithPermissions`, `moveDir` functions
are fixed: now symlinks are copied as they are (before this commit,
they were skipped).
Note:
Inspired by https://docs.python.org/3/library/shutil.html#shutil.copy
and https://en.cppreference.com/w/cpp/filesystem/copy_options1 parent e4a5299 commit efc9a3c
File tree
4 files changed
+315
-111
lines changed- lib/pure
- tests
- stdlib
4 files changed
+315
-111
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
109 | 109 | | |
110 | 110 | | |
111 | 111 | | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
112 | 119 | | |
113 | 120 | | |
114 | 121 | | |
| |||
0 commit comments