PowerShell seems to do file detection well so I haven't seen it run into issues with all sorts of different encodings.