I have a ton of user directories, that I need to move along with permissions to another location, the command I use on an individual basis is :
robocopy "\filer\home" "h:\UserHome" /E /SEC /Copy:DATSOU /log:c:\logfile.txt
Is there a way that robocopy can point to a list of directories in a test file, that need to be moved, instead of doing it one by one which is the way im currently doing.
Create a file named directories.txt:
Then write a Powershell script named RobocopyDirsFromList.ps1:
Note: I've not tested this, please test first.
You need to create folder list file
copy this script and save as BAT/CMD file: