Copied from one of the top suggestions on UserVoice: https://windowsserver.uservoice.com/forums/301869-powershell/suggestions/11087646-implement-native-robocopy-cmdlet
This is a collection of suggestions derived from UserVoice to improve Copy-Item so that it's as robust and feature-laden as Robocopy. (Special thanks to everyone in the UserVoice thread. I'm going to try and summarize all your requests as succinctly as possible here.) The bolded items were particularly popular in the UserVoice thread (and I sorted roughly from most to least popular).
Note that there was also some discussion about adding this functionality to a separate cmdlet so as to avoid complicating Copy-Item too much. I think there's probably a reasonable balance we can strike here.
robocopy /R:n /W:n)robocopy /MIR)robocopy /COPYALL)robocopy /XF foo /XD bar). (Question: what is needed here that isn't fulfilled by Copy-Item -Exclude?)robocopy /B)robocopy /R)robocopy /EFSRAW)robocopy /LOG). (Question: what is not already fulfilled by ConvertTo-Csv?)robocopy /MT[:n])robocopy /IPG:n for "inter-packet gap)robocopy /J)Copy-Item -Robocopy -RobocopySwitches) (in my opinion, this isn't a great idea, especially given cross-plat)Does long paths work with the shipping version of PowerShell?
@RobCannon Windows PowerShell in the Win10 Anniversary Update supports long paths, but you need to enable it for the OS (http://www.howtogeek.com/266621/how-to-make-windows-10-accept-file-paths-over-260-characters), PowerShell Core supports it by default
The first question is whether the functionality in core?
It consists of two parts:
How about just a -NoOverwrite to not overwrite target files, period ... (robocopy /XC /XN /XO??)
I think -NoClobber would be more idiomatic.
we need the options like "-ACL permissionsOnly" & "-NoACL" & "-ProgressBar $true" and
/mir -MirrorSource
I know many, many admins using Robocopy to do backups.
I allways say: if you do not check the integrity of your source <-> destination it is a copy not a backup!
So a verify mechanismm must / should be in the Process. This can be done by a separate cmdlet like Get-FileHash. But this should do it VERY fast and multithreded and IO / Network recource respectful.
So the needs to verify are very similar to Robocopy and they should work together.
So I think it also should be in the Robocopy box.
The Runtime Team is discussing a File.CopyAsync method here
https://github.com/dotnet/runtime/issues/20697
I think @JeremyKuhne is the right guy to ask.
Most helpful comment
I think
-NoClobberwould be more idiomatic.