Expand description
The one “copy a file or folder into a directory” used by drag and drop, paste, and the attachment store’s copy-to-workdir. docs/specs/SPEC_DRAG_AND_DROP_CONSOLIDATION_2026_09_27.md §5.5.
Every destination is created exclusively (create_new, create_dir), so
two copies of report.pdf land as report.pdf and report_1.pdf instead
of racing for one name.
Structs§
Functions§
- copy_
into_ dir - Copy
src(a file, or a folder recursively) intodirundernamemade valid bycopy_nameand de-conflicted. Returns the path it landed at. Symlinks inside a copied folder are skipped, so a link loop can’t recurse. On error or cancel nothing is left behind. - copy_
name - A source file name made valid as one path component on this platform, keeping everything that already is, dotfiles included.