I am using the Unicode version of NSIS to make an installer. I will be appending lines to both ANSI and Unicode files. Before I write a line to a file I need to know whether the file is ANSI encoded or Unicode so I know if I should use FileWrite or FileWriteUTF16LE.
How can I find out the encoding type of a file?
The Unicode Plugin which can tell me the encoding of a file doesn't work for NSIS Unicode, the function unicode::UnicodeType always returns 6.
Any advice would be extremely helpful.