This is the mail archive of the libc-locales@sourceware.org mailing list for the GNU libc locales project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: UTF-8 to <U###> syntax?


Jonathan D. Proulx asked on 2007-03-23:
> anyone have a utility for converting from utf-8 text to the <U####>
> syntax used in the locale files?

The 'iconv' program from GNU libiconv [1] can do it:

  $ echo ÐÑÑÑÐÐÐ |
    iconv -f UTF-8 -t ASCII --unicode-subst='<U%04X>'
  <U0420><U0443><U0441><U0441><U043A><U0438><U0439>

Bruno

[1] http://www.gnu.org/software/libiconv/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]