Using Powershell, how can I detect the text encoding of a file?
For example, I want to know the text encoding for the various .log files under path C:\Windows.
I can list those files easily enough
Get-ChildItem -Filter '*.log' -Path "C:\Windows" -Recurse -ErrorAction SilentlyContinue
But how could I also detect the text encoding for each file? Is there Powershell cmdlet like Get-FileEncoding?