Documentation for routine move assembled from the following pages:
Class: IO::Path §
From IO::Path
(IO::Path) routine move §
Defined as:
method move(IO::Path: IO() , : --> Bool)sub move(IO() , IO() , : --> Bool)
Copies a file and then removes the original. If removal fails, it's possible to end up with two copies of the file. Returns True on success; fails with X::IO::Move if :$createonly is True and the $to path already exists or if the operation failed for some other reason, such as when $to and $from are the same file.
To avoid copying, you can use rename, if the files are on the same storage device. It also works with directories, while move does not.