pwsh-profile relevant part of this is profile1 took it from the fork as some sort of credit for the original author