ICONV(1) Linux Programmer's Manual ICONV(1) NNAAMMEE iconv - character set conversion SSYYNNOOPPSSIISS iconv [_O_P_T_I_O_N...] [--ff _e_n_c_o_d_i_n_g] [--tt _e_n_c_o_d_i_n_g] [_i_n_p_u_t_f_i_l_e ...] iconv --ll DDEESSCCRRIIPPTTIIOONN The iiccoonnvv program converts text from one encoding to another encoding. More precisely, it converts ffrroomm the encoding given for the --ff option ttoo the encoding given for the --tt option. Either of these encodings defaults to the encoding of the current locale. All the _i_n_p_u_t_f_i_l_es are read and converted in turn; if no _i_n_p_u_t_f_i_l_e is given, the standard input is used. The converted text is printed to standard output. The encodings permitted are system dependent. For the libiconv imple- mentation, they are listed in the iconv_open(3) manual page. Options controlling the input and output format: --ff _e_n_c_o_d_i_n_g, ----ffrroomm--ccooddee==_e_n_c_o_d_i_n_g Specifies the encoding of the input. --tt _e_n_c_o_d_i_n_g, ----ttoo--ccooddee==_e_n_c_o_d_i_n_g Specifies the encoding of the output. Options controlling conversion problems: --cc When this option is given, characters that cannot be converted are silently discarded, instead of leading to a conversion error. ----uunniiccooddee--ssuubbsstt==_f_o_r_m_a_t_s_t_r_i_n_g When this option is given, Unicode characters that cannot be represented in the target encoding are replaced with a place- holder string that is constructed from the given _f_o_r_m_a_t_s_t_r_i_n_g, applied to the Unicode code point. The _f_o_r_m_a_t_s_t_r_i_n_g must be a format string in the same format as for the _p_r_i_n_t_f command or the _p_r_i_n_t_f_(_) function, taking either no argument or exactly one unsigned integer argument. ----bbyyttee--ssuubbsstt==_f_o_r_m_a_t_s_t_r_i_n_g When this option is given, bytes in the input that are not valid in the source encoding are replaced with a placeholder string that is constructed from the given _f_o_r_m_a_t_s_t_r_i_n_g, applied to the byte's value. The _f_o_r_m_a_t_s_t_r_i_n_g must be a format string in the same format as for the _p_r_i_n_t_f command or the _p_r_i_n_t_f_(_) function, taking either no argument or exactly one unsigned integer argu- ment. ----wwiiddeecchhaarr--ssuubbsstt==_f_o_r_m_a_t_s_t_r_i_n_g When this option is given, wide characters in the input that are not valid in the source encoding are replaced with a placeholder string that is constructed from the given _f_o_r_m_a_t_s_t_r_i_n_g, applied to the byte's value. The _f_o_r_m_a_t_s_t_r_i_n_g must be a format string in the same format as for the _p_r_i_n_t_f command or the _p_r_i_n_t_f_(_) func- tion, taking either no argument or exactly one unsigned integer argument. Options controlling error output: --ss, ----ssiilleenntt When this option is given, error messages about invalid or unconvertible characters are omitted, but the actual converted text is unaffected. The iiccoonnvv --ll or iiccoonnvv ----lliisstt command lists the names of the supported encodings, in a system dependent format. For the libiconv implementa- tion, the names are printed in upper case, separated by whitespace, and alias names of an encoding are listed on the same line as the encoding itself. EEXXAAMMPPLLEESS iiccoonnvv --ff IISSOO--88885599--11 --tt UUTTFF--88 converts input from the old West-European encoding ISO-8859-1 to Unicode. iiccoonnvv --ff KKOOII88--RR ----bbyyttee--ssuubbsstt==""<<00xx%%xx>>"" ----uunniiccooddee--ssuubbsstt==""<>"" converts input from the old Russian encoding KOI8-R to the locale encoding, substituting an angle bracket notation with hexadecimal numbers for invalid bytes and for valid but uncon- vertible characters. iiccoonnvv ----lliisstt lists the supported encodings. CCOONNFFOORRMMIINNGG TTOO POSIX:2001 SSEEEE AALLSSOO iiccoonnvv__ooppeenn(3), llooccaallee(7) GNU March 31, 2007 ICONV(1)