I found a find-and-replace text answer from another question.
How do I use PowerShell to remove extra spaces at end of line in a text file?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
There are a number of approaches but this one is pretty simple:
You may need to tweak the
Encodingparameter on the Set-Content cmdlet to get the file output in the encoding you want (Unicode, ASCII, UTF8, etc).