We migrated to OneDrive and one of the computers copied folders and added the user name to the end of the folder while still keeping some parts of the folder.
Now we are left with 600 folders. Our base folder is here:
C:\Users\Jason\OneDrive - company files\Company Files
Within it we have all of our project folders which look like this
\(Job Name)\
\(Job Name)-Dave-HP\
Even the subfolders were hit
\(Job Name)\(Subfolder)
\(Job Name)-Dave-HP\(Subfolder)-Dave-HP
Both of these folders have data in them that needs to merge. The script will need to merge the folders and overwrite any duplicate files that exist.
Anyone have any ideas without manually deleting the end off of each folder and letting Explorer merge them? Running Windows 10.
Move-Item
then, are there subfolders also with a trailing-DAVE-HP
or why do you -Recurse?-Dave-HP
are there also conflicting file names, and what to do then - overwrite,rename?