cpSync

external fun cpSync(source: String, destination: String, opts: CopySyncOptions = definedExternally)(source)
external fun cpSync(source: String, destination: URL, opts: CopySyncOptions = definedExternally)(source)
external fun cpSync(source: URL, destination: String, opts: CopySyncOptions = definedExternally)(source)
external fun cpSync(source: URL, destination: URL, opts: CopySyncOptions = definedExternally)(source)

Synchronously copies the entire directory structure from src to dest, including subdirectories and files.

When copying a directory to another directory, globs are not supported and behavior is similar to cp dir1/ dir2/.

Since

v16.7.0

Parameters

src

source path to copy.

dest

destination path to copy to.