Currently working on a project to migrate users over to a new file server. The new server will have a similar name, just one character different. Every user has a personal share mapped using the home folder in Active Directory with a naming convention of their last name and the first letter of their first name. I have the following put together, but I cant figure out how to get the individual paths to set correctly
Get-ADUser -SearchBase "$ou" -Filter * | Set-ADUser -HomeDirectory:"\\$fileserver(LastF Goes Here)\"
Any assistance would be greatly appreciated. My knowledge of how to Powershell drops off a cliff when it gets more complex than a piped command.