I am working with text files that I get from the Windows platform and which are encoded as “Western (Windows Latin 1)”. I am processing these files through an AppleScript and would like to save resulting text files as “Western (Mac OS Roman)” so that some other tool that I’m using interprets all characters correctly.
What I’m doing right now is that I’m opening the Windows text files manually in BBEdit (Open As: Western (Windows Latin 1)), save them as “Western (Mac OS Roman)”, and then run my AppleScript.
I may be able to script BBEdit to do this, but not all my users will have BBEdit, so I want to avoid using BBEdit.
So, my question is: how do I change a Windows Latin 1 encoded file to a Mac OS Roman encoded file? I’ve done some searching, but could not find the answer. Is there a command I can use?