Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'Unix command files, UTF-8, and the byte order mark' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Unix command files, UTF-8, and the byte order mark
Authored by: leamanc on Apr 06, '09 11:44:10AM

I didn't even get but a few sentences into this hint before I realized what the outcome would be. I've found, as others have here, that UTF-8 with BOM is just asking for trouble. I think BareBones should remove that option from BBEdit and TextWrangler! The no-BOM option seems to work great, and is well read across many apps that accept UTF-8.

The only downside from the hinter's perspective is that he has to declare his text encoding in HTML documents, but really you should do that anyway.



[ Reply to This | # ]
Unix command files, UTF-8, and the byte order mark
Authored by: Anonymous on Apr 07, '09 04:46:02PM
Err, no. Don't eliminate useful features. Barebones just needs to extend that features, so that if you save an HTML file, it uses the fancy encoding. But if you save a shell script, it saves it in a format appropriate to that filetype.

[ Reply to This | # ]
Unix command files, UTF-8, and the byte order mark
Authored by: palahala on Apr 08, '09 12:59:09AM

Or if you open a HTML file with no BOM, it could scan for the <meta> header specifying the encoding. Likewise, if it opens XML, it could interpret the encoding attribute.

In fact, I wonder which is considered to be authoritative: the BOM or the encoding as specified in the file.



[ Reply to This | # ]