2 trucs:

1- google charconv
-> www.w3.org/Tools/charconv.html 

extrait du man :
CHARCONV(1)

NAME
  charconv - Conversion of characters between various systems

SYNOPSIS
  charconv [-d|-m|-u] [-f from_table] [-t to_table] [[-i] input_file [-o]
  output_file]

DESCRIPTION
  CHARCONV is a program or filter that allows the transformation of one
  encoding of an extended character set (e.g., ISO Latin-1) to another.
Note
  that the encoding of umlauts, diphthongs, or diacritics is quite
different
  in ISO Latin-1 (Unix, MS Windows), MS DOS (code page 437) or Apple
Macin-
  tosh. Moreover, this program takes care of transcriptions used in TeX or
  HTML (hypertext markup language). Internally, a font description similar
to
  the TeX code (but without math mode) is used. Tags and macros are
removed
  from HTML and TeX input.

  Furthermore, the program allows conversion between different end-of-line
  markers (Unix: LF, DOS: CRLF, Mac: CR).

....


2- howto perso
------------------------------------------------------
pour traduire les fins de lignes des fichiers provenants de
Macintosh en fins de lignes "unix"
en octal : 015 est le caractere CR  vu comme "^M"
en octal : 012 est le caractere LF

cat le_fichier_mac |tr '\015' '\012' > le_fichier_unix
-------------------------------------------------------

->Je dois r�aliser un script Shell traduisant un fichier Mac vers Linux,
->et vice versa (juste pour les fins de ligne). Mon probl�me est que je
->n'ai aucune id�e de la mani�re dont se terminent les lignes sous Mac (je
->sais c'est un peu ubuesque mais bon... :-)).
->
->Quel est la diff�rence entre les fins de ligne Mac et Linux ?
->
->Et (c'est un peu pour cela que ma question est sur cette liste) n'y
->a-t-il pas un �quivalent � dos2unix et unix2dos pour Mac dans les
->paquetages Debian ? J'ai trouv� un mac2unix dans le paquetage uqwk mais
->je n'ai pas trop envie d'installer un tel outil pour cela.
====================================
[EMAIL PROTECTED]

Répondre à