I needed to modify some files with powershell, so I figured it'd be pretty simple:
https://technet.microsoft.com/en-us/library/Hh849882.aspx
Great, there's a cmdlet that handles exactly what I need.
Then I recieved errors when passing the resulting file to the application that was trying to read it. Errors about null characters.
WTF 1: It wrote the file in UCS-2. Isn't UTF-8 standard for everything these days?
So I can just change it to UTF-8, right? Well..
WTF 2: You can't, with native powershell, anyway. Only with clunky .net calling syntax.
If you assume that, since this is dated 2011, that they must have fixed it by now, guess again.
WTF 3: https://connect.microsoft.com/PowerShell/feedbackdetail/view/1137121/add-nobom-flag-to-out-file - Dated 2015
WTFS 4-99: The reason I'm doing this in the first place. I cba to write it up, though.