From 9e1524029fba7208d8740ed7de098960b5928df3 Mon Sep 17 00:00:00 2001 From: CentOS Sources Date: Nov 01 2019 18:40:00 +0000 Subject: import dos2unix-6.0.3-7.el7 --- diff --git a/.dos2unix.metadata b/.dos2unix.metadata new file mode 100644 index 0000000..6563da7 --- /dev/null +++ b/.dos2unix.metadata @@ -0,0 +1 @@ +2c9ae9177fcb0d8b63d141f73a75c928c38ace01 SOURCES/dos2unix-6.0.3.tar.gz diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..56ea8c3 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +SOURCES/dos2unix-6.0.3.tar.gz diff --git a/SOURCES/dos2unix-es.1 b/SOURCES/dos2unix-es.1 new file mode 100644 index 0000000..bd1f861 --- /dev/null +++ b/SOURCES/dos2unix-es.1 @@ -0,0 +1,657 @@ +.\" Automatically generated by Pod::Man 2.27 (Pod::Simple 3.28) +.\" +.\" Standard preamble: +.\" ======================================================================== +.de Sp \" Vertical space (when we can't use .PP) +.if t .sp .5v +.if n .sp +.. +.de Vb \" Begin verbatim text +.ft CW +.nf +.ne \\$1 +.. +.de Ve \" End verbatim text +.ft R +.fi +.. +.\" Set up some character translations and predefined strings. \*(-- will +.\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left +.\" double quote, and \*(R" will give a right double quote. \*(C+ will +.\" give a nicer C++. Capital omega is used to do unbreakable dashes and +.\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, +.\" nothing in troff, for use with C<>. +.tr \(*W- +.ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' +.ie n \{\ +. ds -- \(*W- +. ds PI pi +. if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch +. if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch +. ds L" "" +. ds R" "" +. ds C` "" +. ds C' "" +'br\} +.el\{\ +. ds -- \|\(em\| +. ds PI \(*p +. ds L" `` +. ds R" '' +. ds C` +. ds C' +'br\} +.\" +.\" Escape single quotes in literal strings from groff's Unicode transform. +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" +.\" If the F register is turned on, we'll generate index entries on stderr for +.\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index +.\" entries marked with X<> in POD. Of course, you'll have to process the +.\" output yourself in some meaningful fashion. +.\" +.\" Avoid warning from groff about undefined register 'F'. +.de IX +.. +.nr rF 0 +.if \n(.g .if rF .nr rF 1 +.if (\n(rF:(\n(.g==0)) \{ +. if \nF \{ +. de IX +. tm Index:\\$1\t\\n%\t"\\$2" +.. +. if !\nF==2 \{ +. nr % 0 +. nr F 2 +. \} +. \} +.\} +.rr rF +.\" +.\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2). +.\" Fear. Run. Save yourself. No user-serviceable parts. +. \" fudge factors for nroff and troff +.if n \{\ +. ds #H 0 +. ds #V .8m +. ds #F .3m +. ds #[ \f1 +. ds #] \fP +.\} +.if t \{\ +. ds #H ((1u-(\\\\n(.fu%2u))*.13m) +. ds #V .6m +. ds #F 0 +. ds #[ \& +. ds #] \& +.\} +. \" simple accents for nroff and troff +.if n \{\ +. ds ' \& +. ds ` \& +. ds ^ \& +. ds , \& +. ds ~ ~ +. ds / +.\} +.if t \{\ +. ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u" +. ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u' +. ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u' +. ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u' +. ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u' +. ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u' +.\} +. \" troff and (daisy-wheel) nroff accents +.ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V' +.ds 8 \h'\*(#H'\(*b\h'-\*(#H' +.ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#] +.ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H' +.ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u' +.ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#] +.ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#] +.ds ae a\h'-(\w'a'u*4/10)'e +.ds Ae A\h'-(\w'A'u*4/10)'E +. \" corrections for vroff +.if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u' +.if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u' +. \" for low resolution devices (crt and lpr) +.if \n(.H>23 .if \n(.V>19 \ +\{\ +. ds : e +. ds 8 ss +. ds o a +. ds d- d\h'-1'\(ga +. ds D- D\h'-1'\(hy +. ds th \o'bp' +. ds Th \o'LP' +. ds ae ae +. ds Ae AE +.\} +.rm #[ #] #H #V #F C +.\" ======================================================================== +.\" +.IX Title "dos2unix 1" +.TH dos2unix 1 "2012-09-06" "dos2unix" "2017-03-10" +.\" For nroff, turn off justification. Always turn off hyphenation; it makes +.\" way too many mistakes in technical documents. +.if n .ad l +.nh +.SH "NOMBRE" +.IX Header "NOMBRE" +dos2unix \- Convertidor de archivos de texto de formato DOS/Mac a Unix y viceversa +.SH "SINOPSIS" +.IX Header "SINOPSIS" +.Vb 2 +\& dos2unix [par\['a]metros] [ARCHIVO ...] [\-n ARCH_DE_ENTRADA ARCH_DE_SALIDA ...] +\& unix2dos [par\['a]metros] [ARCHIVO ...] [\-n ARCH_DE_ENTRADA ARCH_DE_SALIDA ...] +.Ve +.SH "DESCRIPCI\['O]N" +.IX Header "DESCRIPCIO'N" +El paquete Dos2unix incluye las utiler\['i]as \f(CW\*(C`dos2unix\*(C'\fR y \f(CW\*(C`unix2dos\*(C'\fR para +convertir archivos de texto plano en formato \s-1DOS\s0 o Mac a formato Unix y viceversa. +.PP +En archivos de texto DOS/Windows, un salto de l\['i]nea, tambi\['e]n conocido como nueva +l\['i]nea, es una combinaci\['o]n de dos caracteres: un retorno de carro (\s-1CR\s0) seguido +por un salto de l\['i]nea (\s-1LF\s0). En archivos de texto Unix, un salto de l\['i]nea es +solamente un car\['a]cter: el salto de l\['i]nea (\s-1LF\s0). En archivos de texto Mac, antes +de Mac \s-1OS X,\s0 un salto de l\['i]nea era s\['o]lo un car\['a]cter retorno de carro (\s-1CR\s0). +Actualmente, Mac \s-1OS\s0 usa el estilo Unix de saltos de l\['i]nea (\s-1LF\s0). +.PP +Los archivos binarios son ignorados autom\['a]ticamente, a menos que se fuerce su +conversi\['o]n. +.PP +Los archivos no regulares, tales como directorios y \s-1FIFO,\s0 son ignorados +autom\['a]ticamente. +.PP +Los enlaces simb\['o]licos y sus destinos no son modificados por defecto. +Los enlaces simb\['o]licos pueden opcionalmente ser reemplazados, o la salida puede +ser escrita al archivo destino del enlace. +Los enlaces simb\['o]licos en Windows no est\['a]n soportados. Estos son siempre +reemplazados, sin que se alteren sus destinos. +.PP +Dos2unix fue moldeado a partir del dos2unix que existe en SunOS/Solaris y tiene +modos de conversi\['o]n similares. +.SH "PAR\['A]METROS" +.IX Header "PARA'METROS" +.IP "\fB\-\-\fR" 4 +.IX Item "--" +Todos los par\['a]metros siguientes son tratados como nombres de archivo. Use este +par\['a]metro si desea convertir archivos cuyos nombres inician con un gui\['o]n. Por +ejemplo para convertir un archivo llamado \*(L"\-foo\*(R", use este comando: +.Sp +.Vb 1 +\& dos2unix \-\- \-foo +.Ve +.Sp +O en modo de archivo nuevo: +.Sp +.Vb 1 +\& dos2unix \-n \-\- \-foo out.txt +.Ve +.IP "\fB\-ascii\fR" 4 +.IX Item "-ascii" +S\['o]lo convierte los salto de l\['i]nea. \['E]ste es el modo de conversi\['o]n por defecto. +.IP "\fB\-iso\fR" 4 +.IX Item "-iso" +Conversi\['o]n entre el conjunto de caracteres \s-1DOS\s0 e \s-1ISO\-8859\-1.\s0 V\['e]ase tambi\['e]n la +secci\['o]n \s-1MODOS DE\s0 CONVERSI\['O]N. +.IP "\fB\-1252\fR" 4 +.IX Item "-1252" +Usa la p\['a]gina de c\['o]digos Windows 1252 (Europa Occidental). +.IP "\fB\-437\fR" 4 +.IX Item "-437" +Usa la p\['a]gina de c\['o]digos \s-1DOS 437 \s0(\s-1EE. UU.\s0). Est\['a] es la p\['a]gina de c\['o]digos usada +por defecto para conversi\['o]n \s-1ISO.\s0 +.IP "\fB\-850\fR" 4 +.IX Item "-850" +Usa la p\['a]gina de c\['o]digos \s-1DOS 850 \s0(Europa Occidental). +.IP "\fB\-860\fR" 4 +.IX Item "-860" +Usa la p\['a]gina de c\['o]digos \s-1DOS 860 \s0(Portugu\['e]s). +.IP "\fB\-863\fR" 4 +.IX Item "-863" +Usa la p\['a]gina de c\['o]digos \s-1DOS 863 \s0(Francocanadiense). +.IP "\fB\-865\fR" 4 +.IX Item "-865" +Usa la p\['a]gina de c\['o]digos \s-1DOS 865 \s0(N\['o]rdico). +.IP "\fB\-7\fR" 4 +.IX Item "-7" +Convierte caracteres de 8 bits al espacio de 7 bits. +.IP "\fB\-c, \-\-convmode \s-1CONVMODE\s0\fR" 4 +.IX Item "-c, --convmode CONVMODE" +Establece el modo de conversi\['o]n, Donde \s-1CONVMODE\s0 puede ser: +\&\fIascii\fR, \fI7bit\fR, \fIiso\fR, \fImac\fR +siendo ascii el valor por defecto. +.IP "\fB\-f, \-\-force\fR" 4 +.IX Item "-f, --force" +Fuerza la conversi\['o]n de archivos binarios. +.IP "\fB\-h, \-\-help\fR" 4 +.IX Item "-h, --help" +Despiega la ayuda y termina el programa. +.IP "\fB\-k, \-\-keepdate\fR" 4 +.IX Item "-k, --keepdate" +Mantiene la fecha del archivo de salida igual a la del archivo de entrada. +.IP "\fB\-L, \-\-license\fR" 4 +.IX Item "-L, --license" +Muestra la licencia del programa. +.IP "\fB\-l, \-\-newline\fR" 4 +.IX Item "-l, --newline" +A\[~n]ade salto de l\['i]nea adicional. +.Sp +\&\fBdos2unix\fR: S\['o]lo los saltos de l\['i]nea \s-1DOS\s0 son cambiados por dos saltos de l\['i]nea +Unix. +En modo Mac s\['o]lo los saltos de l\['i]nea Mac son cambiados por dos saltos de l\['i]nea +Unix. +.Sp +\&\fBunix2dos\fR: S\['o]lo los saltos de l\['i]nea Unix son cambiados por dos saltos de l\['i]nea +\&\s-1DOS.\s0 +En modo Mac los saltos de l\['i]nea Unix son cambiados por dos saltos de l\['i]nea Mac. +.IP "\fB\-m, \-\-add\-bom\fR" 4 +.IX Item "-m, --add-bom" +Escribe una marca de orden de bytes para \s-1UTF\-8\s0 en el archivo de salida. Nunca use esta opci\['o]n cuando +la codificaci\['o]n de salida sea distinta de \s-1UTF\-8.\s0 V\['e]ase tambi\['e]n la secci\['o]n \s-1UNICODE.\s0 +.IP "\fB\-n, \-\-newfile \s-1ARCH_DE_ENTRADA ARCH_DE_SALIDA ...\s0\fR" 4 +.IX Item "-n, --newfile ARCH_DE_ENTRADA ARCH_DE_SALIDA ..." +Modo de archivo nuevo. Convierte el archivo \s-1ARCH_DE_ENTRADA\s0 y escribe la salida +al archivo \s-1ARCH_DE_SALIDA.\s0 +Los nombres de archivo deben ser dados en pares y los comodines \fIno\fR deben ser +usados o \fIperder\['a]\fR sus archivos. +.Sp +La persona que inicia la conversi\['o]n en el modo de archivo nuevo +(pareado) ser\['a] el propietario del archivo convertido. Los permisos de +lectura/escritura del archivo nuevo ser\['a]n los permisos del archivo +original menos la \fIumask\fR\|(1) de la persona que ejecute la conversi\['o]n. +.IP "\fB\-o, \-\-oldfile \s-1ARCHIVO ...\s0\fR" 4 +.IX Item "-o, --oldfile ARCHIVO ..." +Modo de archivo viejo. Convierte el archivo \s-1ARCHIVO\s0 y lo sobrescribe con la salida. +El programa por defecto se ejecuta en este modo. S\['i] se pueden emplear comodines. +.Sp +En modo de archivo antiguo (in situ), el archivo convertido obtiene el +mismo propietario, grupo, y permisos de lectura/escritura que el +archivo original. Lo mismo aplica cuando el archivo es convertido por +otro usuario quien tiene permiso de lectura en el archivo (p.e. usuario +root). La conversi\['o]n ser\['a] abortada cuando no sea posible preservar +los valores originales. Cambiar el propietario implicar\['i]a que el +propietario original ya no podr\['a] leer el archivo. Cambiar el grupo +podr\['i]a ser un riesgo de seguridad, ya que el archivo podr\['i]a ser +accesible a personas inadecuadas. La preservaci\['o]n del propietario, +grupo, y permisos de lectura/escritura s\['o]lo est\['a] soportada bajo Unix. +.IP "\fB\-q, \-\-quiet\fR" 4 +.IX Item "-q, --quiet" +Modo silencioso. Suprime todas las advertencias y mensajes. El valor retornado +es cero. Excepto cuando se emplean par\['a]metros incorrectos. +.IP "\fB\-s, \-\-safe\fR" 4 +.IX Item "-s, --safe" +Ignora los archivos binarios (por defecto). +.IP "\fB\-F, \-\-follow\-symlink\fR" 4 +.IX Item "-F, --follow-symlink" +Sigue los enlaces simb\['o]licos y convierte los destinos. +.IP "\fB\-R, \-\-replace\-symlink\fR" 4 +.IX Item "-R, --replace-symlink" +Reemplaza los enlaces simb\['o]licos con los archivos convertidos +(los archivos destino originales no se alteran). +.IP "\fB\-S, \-\-skip\-symlink\fR" 4 +.IX Item "-S, --skip-symlink" +No altera los enlaces simb\['o]licos ni sus destinos (por defecto). +.IP "\fB\-V, \-\-version\fR" 4 +.IX Item "-V, --version" +Despiega la informaci\['o]n de la versi\['o]n y termina el programa. +.SH "MODO MAC" +.IX Header "MODO MAC" +En modo normal los saltos de l\['i]nea son convertidos de \s-1DOS\s0 a Unix y viceversa. +Los saltos de l\['i]nea Mac no son convertidos. +.PP +En modo Mac los saltos de l\['i]nea son convertidos de Mac a Unix y viceversa. Los +saltos de l\['i]nea \s-1DOS\s0 no son modificados. +.PP +Para ejecutar en modo Mac use el modificador \f(CW\*(C`\-c mac\*(C'\fR o use los comandos +\&\f(CW\*(C`mac2unix\*(C'\fR o \f(CW\*(C`unix2mac\*(C'\fR. +.SH "MODOS DE CONVERSI\['O]N" +.IX Header "MODOS DE CONVERSIO'N" +Los modos de conversi\['o]n \fIascii\fR, \fI7bit\fR, e \fIiso\fR son similares a los de +los comandos dos2unix/unix2dos de SunOS/Solaris. +.IP "\fBascii\fR" 4 +.IX Item "ascii" +En modo \f(CW\*(C`ascii\*(C'\fR s\['o]lo los saltos de l\['i]nea son convertidos. \['E]ste es el modo de +conversi\['o]n por defecto. +.Sp +Aunque el nombre de este modo es \s-1ASCII,\s0 el cual es un est\['a]ndar de 7 bits, \['e]ste +emplea 8 bits. Siempre use este modo cuando convierta archivos en Unicode \s-1UTF\-8.\s0 +.IP "\fB7bit\fR" 4 +.IX Item "7bit" +En este modo todos los caracteres no \s-1ASCII\s0 de 8 bits (con valores de 128 a 255) +son convertidos al espacio de 7 bits. +.IP "\fBiso\fR" 4 +.IX Item "iso" +Los caracteres son convertidos entre un conjunto de caracteres \s-1DOS \s0(p\['a]gina de +c\['o]digos) y el conjunto de caracteres \s-1ISO\-8859\-1 \s0(Lat\['i]n\-1) de Unix. Los +caracteres \s-1DOS\s0 sin equivalente \s-1ISO\-8859\-1,\s0 para los cuales la conversi\['o]n es +imposible, son convertidos en un punto. Lo mismo se aplica para caracteres +\&\s-1ISO\-8859\-1\s0 sin contraparte \s-1DOS.\s0 +.Sp +Cuando s\['o]lo se emplea el par\['a]metro \f(CW\*(C`\-iso\*(C'\fR, dos2unix intentar\['a] determinar la +p\['a]gina de c\['o]digos activa. Cuando esto no sea posible, dos2unix utilizar\['a] la +p\['a]gina de c\['o]digos 437 por defecto, la cual es empleada principalmente en \s-1EE. UU.\s0 +Para forzar una p\['a]gina de c\['o]digos espec\['i]fica emplee los par\['a]metros +\&\f(CW\*(C`\-437\*(C'\fR (\s-1EE. UU.\s0), \f(CW\*(C`\-850\*(C'\fR (Europa Occidental), \f(CW\*(C`\-860\*(C'\fR (Portugu\['e]s), +\&\f(CW\*(C`\-863\*(C'\fR (Francocanadiense), o \f(CW\*(C`\-865\*(C'\fR (N\['o]rdico). La p\['a]gina de c\['o]digos Windows +1252 (Europa Occidental) tambi\['e]n est\['a] soportada con el par\['a]metro \f(CW\*(C`\-1252\*(C'\fR. Para +acceder a otras p\['a]ginas de c\['o]digos use dos2unix en combinaci\['o]n con \fIiconv\fR\|(1). +Iconv puede convertir entre una larga lista de codificaciones de caracteres. +.Sp +Nunca emplee la conversi\['o]n \s-1ISO\s0 en archivos de texto Unicode. Esto corromper\['a] +los archivos codificados como \s-1UTF\-8.\s0 +.Sp +Algunos ejemplos: +.Sp +Convierte de la p\['a]gina de c\['o]digos por defecto de \s-1DOS\s0 a Lat\['i]n\-1 de Unix. +.Sp +.Vb 1 +\& dos2unix \-iso \-n in.txt out.txt +.Ve +.Sp +Convierte de \s-1DOS 850\s0 a Unix Lat\['i]n\-1. +.Sp +.Vb 1 +\& dos2unix \-850 \-n in.txt out.txt +.Ve +.Sp +Convierte de Windows 1252 a Unix Lat\['i]n\-1. +.Sp +.Vb 1 +\& dos2unix \-1252 \-n in.txt out.txt +.Ve +.Sp +Convierte de Windows 1252 a Unix \s-1UTF\-8 \s0(Unicode). +.Sp +.Vb 1 +\& iconv \-f CP1252 \-t UTF\-8 in.txt | dos2unix > out.txt +.Ve +.Sp +Convierte de Unix Lat\['i]n\-1 a la p\['a]gina de c\['o]digos por defecto de \s-1DOS.\s0 +.Sp +.Vb 1 +\& unix2dos \-iso \-n in.txt out.txt +.Ve +.Sp +Convierte de Unix Lat\['i]n\-1 a \s-1DOS 850.\s0 +.Sp +.Vb 1 +\& unix2dos \-850 \-n in.txt out.txt +.Ve +.Sp +Convierte de Unix Lat\['i]n\-1 a Windows 1252. +.Sp +.Vb 1 +\& unix2dos \-1252 \-n in.txt out.txt +.Ve +.Sp +Convierte de Unix \s-1UTF\-8 \s0(Unicode) a Windows 1252. +.Sp +.Vb 1 +\& unix2dos < in.txt | iconv \-f UTF\-8 \-t CP1252 > out.txt +.Ve +.Sp +V\['e]ase tambi\['e]n +y . +.SH "UNICODE" +.IX Header "UNICODE" +.SS "Codificaciones" +.IX Subsection "Codificaciones" +Existen diferentes codificaciones Unicode. En Unix y Linux los archivos Unicode +son codificados com\['u]nmente como \s-1UTF\-8.\s0 En Windows los archivos de texto Unicode +pueden estar codificados en \s-1UTF\-8, UTF\-16,\s0 o \s-1UTF\-16\s0 big endian, pero con m\['a]s +frecuencia son codificados en formato \s-1UTF\-16.\s0 +.SS "Conversion" +.IX Subsection "Conversion" +Los archivos de texto Unicode pueden tener saltos de l\['i]nea \s-1DOS,\s0 Unix o Mac, como +cualquier archivo de texto. +.PP +Todas las versiones de dos2unix y unix2dos pueden convertir archivos codificados +como \s-1UTF\-8,\s0 debido a que \s-1UTF\-8\s0 fue dise\[~n]ado para retro-compatibilidad con \s-1ASCII.\s0 +.PP +Dos2unix y unix2dos con soporte Unicode \s-1UTF\-16,\s0 pueden leer archivos de texto +codificados como \s-1UTF\-16\s0 little y big endian. Para ver si dos2unix fue compilado con +soporte \s-1UTF\-16\s0 escriba \f(CW\*(C`dos2unix \-V\*(C'\fR. +.PP +Las versiones Windows de dos2unix y unix2dos siempre convierten archivos +Codificados como \s-1UTF\-16\s0 a \s-1UTF\-8.\s0 Las versiones Unix de dos2unix/unix2dos +convierten archivos \s-1UTF\-16\s0 a la codificaci\['o]n de caracteres local cuando es +configurado a \s-1UTF\-8.\s0 +Emplee el comando \fIlocale\fR\|(1) para determinar cual es la codificaci\['o]n de caracteres +local. +.PP +Dado que los archivos de texto formateados \s-1UTF\-8\s0 son bien soportados tanto en +Windows como en Unix, dos2unix y unix2dos no tienen opci\['o]n para escribir +archivos \s-1UTF\-16.\s0 Todos los caracteres \s-1UTF\-16\s0 pueden ser codificados en +\&\s-1UTF\-8.\s0 La conversi\['o]n de \s-1UTF\-16\s0 a \s-1UTF\-8\s0 ocurre sin p\['e]rdida. Los archivos +\&\s-1UTF\-16\s0 ser\['a]n ignorados en Unix cuando la codificaci\['o]n de caracteres local no +sea \s-1UTF\-8,\s0 para evitar la p\['e]rdida accidental de texto. Cuando ocurre un error +de conversi\['o]n de \s-1UTF\-16\s0 a \s-1UTF\-8,\s0 por ejemplo cuando el archivo de entrada +\&\s-1UTF\-16\s0 contiene un error, el archivo ser\['a] ignorado. +.PP +La conversi\['o]n en modos \s-1ISO\s0 y 7\-bit no funciona en archivos \s-1UTF\-16.\s0 +.SS "Marca de orden de bytes" +.IX Subsection "Marca de orden de bytes" +En Windows los archivos de texto Unicode t\['i]picamente tienen una marca de orden de +bytes (\s-1BOM\s0), debido a que muchos programas de Windows (incluyendo el Bloc de notas) +a\[~n]aden una \s-1BOM\s0 por defecto. V\['e]ase tambi\['e]n +. +.PP +En Unix los archivos Unicode t\['i]picamente no tienen una \s-1BOM.\s0 Se supone que los archivos +de texto son codificados en la codificaci\['o]n de caracteres local. +.PP +Dos2unix s\['o]lo puede detectar si un archivo est\['a] en formato \s-1UTF\-16\s0 si el archivo +tiene una \s-1BOM.\s0 +Cuando un archivo \s-1UTF\-16\s0 no tiene una \s-1BOM,\s0 dos2unix tratar\['a] el archivo como un +archivo binario. +.PP +Emplee dos2unix en combinaci\['o]n con \fIiconv\fR\|(1) para convertir un archivo \s-1UTF\-16\s0 sin +una \s-1BOM.\s0 +.PP +Dos2unix nunca escribe una \s-1BOM\s0 en el archivo de salida, a menos que emplee la +opci\['o]n \f(CW\*(C`\-m\*(C'\fR. +.PP +Unix2dos escribe una \s-1BOM\s0 en el archivo de salida cuando el archivo de entrada tiene +una \s-1BOM,\s0 o cuando se emplea la opci\['o]n \f(CW\*(C`\-m\*(C'\fR. +.SS "Ejemplos Unicode" +.IX Subsection "Ejemplos Unicode" +Convertir de Windows \s-1UTF\-16 \s0(con una \s-1BOM\s0) a Unix \s-1UTF\-8\s0 +.PP +.Vb 1 +\& dos2unix \-n in.txt out.txt +.Ve +.PP +Convertir de Windows \s-1UTF\-16 \s0(sin una \s-1BOM\s0) a Unix \s-1UTF\-8\s0 +.PP +.Vb 1 +\& iconv \-f UTF\-16 \-t UTF\-8 in.txt | dos2unix > out.txt +.Ve +.PP +Convertir de Unix \s-1UTF\-8\s0 a Windows \s-1UTF\-8\s0 sin una \s-1BOM\s0 +.PP +.Vb 1 +\& unix2dos \-m \-n in.txt out.txt +.Ve +.PP +Convertir de Unix \s-1UTF\-8\s0 a Windows \s-1UTF\-16\s0 +.PP +.Vb 1 +\& unix2dos < in.txt | iconv \-f UTF\-8 \-t UTF\-16 > out.txt +.Ve +.SH "EJEMPLOS" +.IX Header "EJEMPLOS" +Lee la entrada desde 'stdin' y escribe la salida a 'stdout'. +.PP +.Vb 2 +\& dos2unix +\& dos2unix \-l \-c mac +.Ve +.PP +Convierte y reemplaza a.txt. Convierte y reemplaza b.txt. +.PP +.Vb 2 +\& dos2unix a.txt b.txt +\& dos2unix \-o a.txt b.txt +.Ve +.PP +Convierte y reemplaza a.txt empleando modo de conversi\['o]n ascii. +.PP +.Vb 1 +\& dos2unix a.txt +.Ve +.PP +Convierte y reemplaza a.txt empleando modo de conversi\['o]n ascii. +Convierte y reemplaza b.txt empleando modo de conversi\['o]n de 7bits. +.PP +.Vb 3 +\& dos2unix a.txt \-c 7bit b.txt +\& dos2unix \-c ascii a.txt \-c 7bit b.txt +\& dos2unix \-ascii a.txt \-7 b.txt +.Ve +.PP +Convierte a.txt del formato de Mac a Unix. +.PP +.Vb 2 +\& dos2unix \-c mac a.txt +\& mac2unix a.txt +.Ve +.PP +Convierte a.txt del formato de Unix a Mac. +.PP +.Vb 2 +\& unix2dos \-c mac a.txt +\& unix2mac a.txt +.Ve +.PP +Convierte y reemplaza a.txt manteniendo la fecha del archivo original. +.PP +.Vb 2 +\& dos2unix \-k a.txt +\& dos2unix \-k \-o a.txt +.Ve +.PP +Convierte a.txt y escribe la salida a e.txt. +.PP +.Vb 1 +\& dos2unix \-n a.txt e.txt +.Ve +.PP +Convierte a.txt y escribe la salida a e.txt, manteniendo la fecha de e.txt +igual a la de a.txt. +.PP +.Vb 1 +\& dos2unix \-k \-n a.txt e.txt +.Ve +.PP +Convierte y reemplaza a.txt. Convierte b.txt y escribe a e.txt. +.PP +.Vb 2 +\& dos2unix a.txt \-n b.txt e.txt +\& dos2unix \-o a.txt \-n b.txt e.txt +.Ve +.PP +Convierte c.txt y escribe a e.txt. Convierte y reemplaza a.txt. +Convierte y reemplaza b.txt. Convierte d.txt y escribe a f.txt. +.PP +.Vb 1 +\& dos2unix \-n c.txt e.txt \-o a.txt b.txt \-n d.txt f.txt +.Ve +.SH "CONVERSI\['O]N RECURSIVA" +.IX Header "CONVERSIO'N RECURSIVA" +Emplee dos2unix en combinaci\['o]n con los comandos \fIfind\fR\|(1) y \fIxargs\fR\|(1) para +convertir recursivamente archivos de texto contenidos en un \['a]rbol de directorios. +Por ejemplo para convertir todos los archivos .txt en el \['a]rbol de directorios debajo +del directorio actual escriba: +.PP +.Vb 1 +\& find . \-name *.txt |xargs dos2unix +.Ve +.SH "INTERNACIONALIZACI\['O]N" +.IX Header "INTERNACIONALIZACIO'N" +.IP "\fB\s-1LANG\s0\fR" 4 +.IX Item "LANG" +El idioma principal se selecciona con la variable de entorno \s-1LANG.\s0 La variable +\&\s-1LANG\s0 consiste de varias partes. La primer parte es el c\['o]digo del idioma en +min\['u]sculas. La segunda es opcional y es el c\['o]digo del pa\['i]s en may\['u]sculas, +precedido por un gui\['o]n bajo. Existe tambi\['e]n una tercera parte opcional: la +codificaci\['o]n de caracteres, precedida por un punto. Unos cuantos ejemplos para +int\['e]rpretes de comandos tipo \s-1POSIX\s0 est\['a]ndar: +.Sp +.Vb 7 +\& export LANG=nl Neerland\['e]s +\& export LANG=nl_NL Neerland\['e]s, Pa\['i]ses Bajos +\& export LANG=nl_BE Neerland\['e]s, B\['e]lgica +\& export LANG=es_ES Espa\[~n]ol, Espa\[~n]a +\& export LANG=es_MX Espa\[~n]ol, M\['e]xico +\& export LANG=en_US.iso88591 Ingles, EE. UU., codificaci\['o]n Lat\['i]n\-1 +\& export LANG=en_GB.UTF\-8 Ingles, Reino Unido, codificaci\['o]n UTF\-8 +.Ve +.Sp +Para una lista completa de c\['o]digos de idioma y pa\['i]s v\['e]ase el manual de gettext: + +.Sp +En sistemas Unix puede emplear el comando \fIlocale\fR\|(1) para obtener informaci\['o]n +espec\['i]fica del locale. +.IP "\fB\s-1LANGUAGE\s0\fR" 4 +.IX Item "LANGUAGE" +Con la variable de entorno \s-1LANGUAGE\s0 puede especificar una lista de prioridad +de los idiomas, separados por dos puntos. Dos2unix da preferencia a \s-1LANGUAGE\s0 +por encima de \s-1LANG.\s0 Por ejemplo, primero neerland\['e]s y entonces alem\['a]n: +\&\f(CW\*(C`LANGUAGE=nl:de\*(C'\fR. Antes de que pueda usar una lista de prioridad de idiomas a +trav\['e]s de la variable \s-1LANGUAGE,\s0 primero tiene que habilitar la +internacionalizaci\['o]n, mediante asignar un valor distinto de \*(L"C\*(R" a \s-1LANG +\&\s0(o \s-1LC_ALL\s0). V\['e]ase tambi\['e]n el manual de gettext: + +.Sp +Si selecciona un idioma que no est\['a] disponible el programa funcionar\['a] en ingles. +.IP "\fB\s-1DOS2UNIX_LOCALEDIR\s0\fR" 4 +.IX Item "DOS2UNIX_LOCALEDIR" +Con la variable de entorno \s-1DOS2UNIX_LOCALEDIR\s0 el \s-1LOCALEDIR\s0 asignado durante +la compilaci\['o]n puede ser modificado. \s-1LOCALEDIR\s0 es usado para encontrar los +archivos de idioma. El valor por defecto de \s-1GNU\s0 es \f(CW\*(C`/usr/local/share/locale\*(C'\fR. +El par\['a]metro \fB\-\-version\fR desplegar\['a] el \s-1LOCALEDIR\s0 en uso. +.Sp +Ejemplo (int\['e]rprete de comandos \s-1POSIX\s0): +.Sp +.Vb 1 +\& export DOS2UNIX_LOCALEDIR=$HOME/share/locale +.Ve +.SH "VALOR DE RETORNO" +.IX Header "VALOR DE RETORNO" +Se regresa cero cuando el programa termina exitosamente. Cuando ocurre un error +del sistema se regresar\['a] el \['u]ltimo n\['u]mero de error del sistema. Para otros errores +se regresa 1. +.PP +El valor de retorno es siempre cero en modo silencioso, excepto cuando se +emplean par\['a]metros incorrectos. +.SH "EST\['A]NDARES" +.IX Header "ESTA'NDARES" + +.PP + +.PP + +.PP + +.SH "AUTORES" +.IX Header "AUTORES" +Benjamin Lin \- +Bernd Johannes Wuebben (modo mac2unix) \- , +Christian Wurll (a\[~n]adi\['o] el salto de l\['i]nea extra) \- , +Erwin Waterlander \- (Mantenimiento) +.PP +P\['a]gina del proyecto: +.PP +P\['a]gina de SourceForge: +.PP +Freecode: +.SH "V\['E]ASE TAMBI\['E]N" +.IX Header "VE'ASE TAMBIE'N" +\&\fIfile\fR\|(1) +\&\fIfind\fR\|(1) +\&\fIiconv\fR\|(1) +\&\fIlocale\fR\|(1) +\&\fIxargs\fR\|(1) diff --git a/SOURCES/dos2unix-nl.1 b/SOURCES/dos2unix-nl.1 new file mode 100644 index 0000000..e59683a --- /dev/null +++ b/SOURCES/dos2unix-nl.1 @@ -0,0 +1,645 @@ +.\" Automatically generated by Pod::Man 2.27 (Pod::Simple 3.28) +.\" +.\" Standard preamble: +.\" ======================================================================== +.de Sp \" Vertical space (when we can't use .PP) +.if t .sp .5v +.if n .sp +.. +.de Vb \" Begin verbatim text +.ft CW +.nf +.ne \\$1 +.. +.de Ve \" End verbatim text +.ft R +.fi +.. +.\" Set up some character translations and predefined strings. \*(-- will +.\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left +.\" double quote, and \*(R" will give a right double quote. \*(C+ will +.\" give a nicer C++. Capital omega is used to do unbreakable dashes and +.\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, +.\" nothing in troff, for use with C<>. +.tr \(*W- +.ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' +.ie n \{\ +. ds -- \(*W- +. ds PI pi +. if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch +. if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch +. ds L" "" +. ds R" "" +. ds C` "" +. ds C' "" +'br\} +.el\{\ +. ds -- \|\(em\| +. ds PI \(*p +. ds L" `` +. ds R" '' +. ds C` +. ds C' +'br\} +.\" +.\" Escape single quotes in literal strings from groff's Unicode transform. +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" +.\" If the F register is turned on, we'll generate index entries on stderr for +.\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index +.\" entries marked with X<> in POD. Of course, you'll have to process the +.\" output yourself in some meaningful fashion. +.\" +.\" Avoid warning from groff about undefined register 'F'. +.de IX +.. +.nr rF 0 +.if \n(.g .if rF .nr rF 1 +.if (\n(rF:(\n(.g==0)) \{ +. if \nF \{ +. de IX +. tm Index:\\$1\t\\n%\t"\\$2" +.. +. if !\nF==2 \{ +. nr % 0 +. nr F 2 +. \} +. \} +.\} +.rr rF +.\" +.\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2). +.\" Fear. Run. Save yourself. No user-serviceable parts. +. \" fudge factors for nroff and troff +.if n \{\ +. ds #H 0 +. ds #V .8m +. ds #F .3m +. ds #[ \f1 +. ds #] \fP +.\} +.if t \{\ +. ds #H ((1u-(\\\\n(.fu%2u))*.13m) +. ds #V .6m +. ds #F 0 +. ds #[ \& +. ds #] \& +.\} +. \" simple accents for nroff and troff +.if n \{\ +. ds ' \& +. ds ` \& +. ds ^ \& +. ds , \& +. ds ~ ~ +. ds / +.\} +.if t \{\ +. ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u" +. ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u' +. ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u' +. ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u' +. ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u' +. ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u' +.\} +. \" troff and (daisy-wheel) nroff accents +.ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V' +.ds 8 \h'\*(#H'\(*b\h'-\*(#H' +.ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#] +.ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H' +.ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u' +.ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#] +.ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#] +.ds ae a\h'-(\w'a'u*4/10)'e +.ds Ae A\h'-(\w'A'u*4/10)'E +. \" corrections for vroff +.if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u' +.if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u' +. \" for low resolution devices (crt and lpr) +.if \n(.H>23 .if \n(.V>19 \ +\{\ +. ds : e +. ds 8 ss +. ds o a +. ds d- d\h'-1'\(ga +. ds D- D\h'-1'\(hy +. ds th \o'bp' +. ds Th \o'LP' +. ds ae ae +. ds Ae AE +.\} +.rm #[ #] #H #V #F C +.\" ======================================================================== +.\" +.IX Title "dos2unix 1" +.TH dos2unix 1 "2012-09-06" "dos2unix" "2017-03-10" +.\" For nroff, turn off justification. Always turn off hyphenation; it makes +.\" way too many mistakes in technical documents. +.if n .ad l +.nh +.SH "NAAM" +.IX Header "NAAM" +dos2unix \- DOS/Mac naar Unix en vice versa tekstbestand formaat omzetter +.SH "OVERZICHT" +.IX Header "OVERZICHT" +.Vb 2 +\& dos2unix [opties] [BESTAND ...] [\-n INVOERBESTAND UITVOERBESTAND ...] +\& unix2dos [opties] [BESTAND ...] [\-n INVOERBESTAND UITVOERBESTAND ...] +.Ve +.SH "BESCHRIJVING" +.IX Header "BESCHRIJVING" +Het Dos2unix pakket bevat toepassingen \f(CW\*(C`dos2unix\*(C'\fR en \f(CW\*(C`unix2dos\*(C'\fR om +platte tekstbestanden in \s-1DOS\s0 of Mac formaat naar Unix om te zetten en +vice versa. +.PP +In DOS/Windows tekstbestanden bestaat een regeleinde uit een combinatie van +twee tekens: een 'Carriage Return' (\s-1CR\s0) gevolgd door een 'Line Feed' (\s-1LF\s0). In +Unix tekstbestanden bestaat een regeleinde uit een enkel 'Newline' teken die +gelijk is aan een \s-1DOS \s0'Line Feed' (\s-1LF\s0) teken. In Mac tekst bestanden, voor Mac +\&\s-1OS X,\s0 bestaan regeleindes uit een enkel 'Carriage Return' teken. Mac \s-1OS X\s0 is +Unix gebaseerd en heeft dezelfde regeleindes als Unix. +.PP +Binaire bestanden worden automatisch overgeslagen, behalve als de omzetting +geforceerd wordt. +.PP +Niet-reguliere bestanden, zoals mappen en FIFOs, worden automatisch overgeslagen. +.PP +Symbolische koppelingen en hun doelen blijven standaard onaangeroerd. +Optioneel kunnen symbolische koppelingen worden vervangen, of de uitvoer +kan naar het doel van de symbolische koppeling worden geschreven. +Symbolische koppelingen op Windows worden niet ondersteund. Windows +symbolische koppelingen worden altijd vervangen, de doelen onaangeroerd +gelaten. +.PP +Dos2unix is gemodelleerd naar dos2unix onder SunOS/Solaris en heeft gelijke conversiemodi. +.SH "OPTIES" +.IX Header "OPTIES" +.IP "\fB\-\-\fR" 4 +.IX Item "--" +Behandel alle volgende opties als bestandsnamen. Gebruik deze optie +als je bestanden wil converteren wiens naam met een streepje begint. +Bijvoorbeeld, om een bestand genaamd \*(L"\-foo\*(R" om te zetten, gebruik je +de volgende opdracht: +.Sp +.Vb 1 +\& dos2unix \-\- \-foo +.Ve +.Sp +Of in nieuw-bestand-modus: +.Sp +.Vb 1 +\& dos2unix \-n \-\- \-foo uit.txt +.Ve +.IP "\fB\-ascii\fR" 4 +.IX Item "-ascii" +Converteer alleen regeleindes. Dit is de standaard conversiemodus. +.IP "\fB\-iso\fR" 4 +.IX Item "-iso" +Conversie tussen \s-1DOS\s0 en \s-1ISO\-8859\-1\s0 lettertekenreeks. Zie ook paragraaf +\&\s-1CONVERSIEMODI.\s0 +.IP "\fB\-1252\fR" 4 +.IX Item "-1252" +Gebruik Windows codetabel 1252 (West-Europees). +.IP "\fB\-437\fR" 4 +.IX Item "-437" +Gebruik \s-1DOS\s0 codetabel 437 (\s-1VS\s0). Dit is de standaard codetabel die gebruikt wordt bij \s-1ISO\s0 conversie. +.IP "\fB\-850\fR" 4 +.IX Item "-850" +Gebruik \s-1DOS\s0 codetabel 850 (West-Europees). +.IP "\fB\-860\fR" 4 +.IX Item "-860" +Gebruik \s-1DOS\s0 codetabel 860 (Portugees). +.IP "\fB\-863\fR" 4 +.IX Item "-863" +Gebruik \s-1DOS\s0 codetabel 863 (Canadees Frans). +.IP "\fB\-865\fR" 4 +.IX Item "-865" +Gebruik \s-1DOS\s0 codetabel 865 (Scandinavisch). +.IP "\fB\-7\fR" 4 +.IX Item "-7" +Converteer 8 bit lettertekens naar 7 bit spatie. +.IP "\fB\-c, \-\-convmode \s-1CONVMODUS\s0\fR" 4 +.IX Item "-c, --convmode CONVMODUS" +Stel conversiemodus in. Waarbij \s-1CONVMODUS\s0 een is van: +\&\fIascii\fR, \fI7bit\fR, \fIiso\fR, \fImac\fR +met ascii als standaard instelling. +.IP "\fB\-f, \-\-force\fR" 4 +.IX Item "-f, --force" +Forceer omzetting van binaire bestanden. +.IP "\fB\-h, \-\-help\fR" 4 +.IX Item "-h, --help" +Laat help tekst zien. +.IP "\fB\-k, \-\-keepdate\fR" 4 +.IX Item "-k, --keepdate" +Behoud de datum van het invoerbestand in het uitvoerbestand. +.IP "\fB\-L, \-\-license\fR" 4 +.IX Item "-L, --license" +Laat de software licentie zien. +.IP "\fB\-l, \-\-newline\fR" 4 +.IX Item "-l, --newline" +Voeg een extra regeleinde toe. +.Sp +\&\fBdos2unix\fR: Alleen \s-1DOS\s0 regeleindes worden omgezet naar twee Unix regeleindes. +In Mac modus worden alleen Mac regeleindes omgezet naar twee Unix regeleindes. +.Sp +\&\fBunix2dos\fR: Aleen Unix regeleindes worden omgezet naar twee \s-1DOS\s0 regeleindes. +In Mac modus worden Unix regeleindes omgezet naar twee Mac regeleindes. +.IP "\fB\-m, \-\-add\-bom\fR" 4 +.IX Item "-m, --add-bom" +Schrijf een \s-1UTF\-8\s0 Byte Order Mark in het uitvoerbestand. Gebruik deze optie +nooit als de codering het van uitvoerbestand geen \s-1UTF\-8\s0 is. Zie ook paragraaf +\&\s-1UNICODE.\s0 +.IP "\fB\-n, \-\-newfile \s-1INVOERBESTAND UITVOERBESTAND ...\s0\fR" 4 +.IX Item "-n, --newfile INVOERBESTAND UITVOERBESTAND ..." +Nieuw-bestand-modus. Converteer bestand \s-1INVOERBESTAND\s0 en schrijf naar bestand +\&\s-1UITVOERBESTAND.\s0 Bestandsnamen moeten opgegeven worden in paren. Jokertekens +moeten \s-1NIET\s0 gebruikt worden, anders verlies je bestanden. +.Sp +De persoon die de conversie start in nieuw-bestand (gepaarde) modus wordt +de eigenaar van het geconverteerde bestand. De lees/schrijf permissies van +het nieuwe bestand worden de permissies van het originele bestand minus de +\&\fIumask\fR\|(1) van de persoon die de conversie draait. +.IP "\fB\-o, \-\-oldfile \s-1BESTAND ...\s0\fR" 4 +.IX Item "-o, --oldfile BESTAND ..." +Oud-bestand-modus. Converteer bestand \s-1BESTAND\s0 en overschrijf het. +Dit is de standaard modus. Jokertekens kunnen gebruikt worden. +.Sp +In oud-bestand (plaatsvervangende) modus krijgt het geconverteerde bestand +dezelfde eigenaar, groep en lees/schrijf rechten als het originele +bestand. Ook wanneer het bestand wordt omgezet door een andere gebruiker +die schrijfrechten heeft op het bestand (b.v. gebruiker root). De +omzetting wordt afgebroken wanneer het niet mogelijk is de originele +waardes te behouden. Verandering van eigenaar kan betekenen dat de +originele eigenaar het bestand niet meer kan lezen. Verandering van groep +zou een veiligheidsrisico kunnen zijn, het bestand zou leesbaar kunnen +worden voor personen voor wie het niet bestemd is. Behoud van eigenaar, +groep en lees/schrijf rechten is alleen ondersteund op Unix. +.IP "\fB\-q, \-\-quiet\fR" 4 +.IX Item "-q, --quiet" +Stille werking. Onderdruk alle waarschuwingen. De teruggave waarde is nul. +Behalve wanneer verkeerde opties worden gegeven. +.IP "\fB\-s, \-\-safe\fR" 4 +.IX Item "-s, --safe" +Sla binaire bestanden over (standaard). +.IP "\fB\-F, \-\-follow\-symlink\fR" 4 +.IX Item "-F, --follow-symlink" +Volg symbolische koppelingen en coverteer de doelen. +.IP "\fB\-R, \-\-replace\-symlink\fR" 4 +.IX Item "-R, --replace-symlink" +Vervang symbolische koppelingen door geconverteerde bestanden +(originele doelbestanden blijven ongewijzigd). +.IP "\fB\-S, \-\-skip\-symlink\fR" 4 +.IX Item "-S, --skip-symlink" +Laat symbolische koppelingen en doelen ongewijzigd (standaard). +.IP "\fB\-V, \-\-version\fR" 4 +.IX Item "-V, --version" +Laat versie informatie zien. +.SH "MAC MODUS" +.IX Header "MAC MODUS" +In normale modus worden \s-1DOS\s0 regeleindes naar Unix omgezet en vice versa. Mac regeleindes worden niet omgezet. +.PP +In Mac modus worden Mac regeleindes naar Unix omgezet en vice versa. \s-1DOS\s0 regeleindes blijven ongewijzigd. +.PP +Om in Mac modus te draaien gebruik de schakeloptie \f(CW\*(C`\-c mac\*(C'\fR of gebruik de opdrachten \f(CW\*(C`mac2unix\*(C'\fR of \f(CW\*(C`unix2mac\*(C'\fR. +.SH "CONVERSIEMODI" +.IX Header "CONVERSIEMODI" +Conversie-modi \fIascii\fR, \fI7bit\fR, en \fIiso\fR +zijn gelijk aan die van dos2unix/unix2dos onder SunOS/Solaris. +.IP "\fBascii\fR" 4 +.IX Item "ascii" +In modus \f(CW\*(C`ascii\*(C'\fR worden alleen regeleindes omgezet. Dit is de standaard modus. +.Sp +Hoewel de naam van deze modus \s-1ASCII\s0 is, wat een 7 bit standaard is, is de +werkelijke modus 8 bit. Gebruik altijd deze modus wanneer u Unicode \s-1UTF\-8\s0 +bestanden omzet. +.IP "\fB7bit\fR" 4 +.IX Item "7bit" +Alle 8 bit niet-ASCII lettertekens (met waardes van 128 t/m 255) worden +omgezet naar een 7 bit spatie. +.IP "\fBiso\fR" 4 +.IX Item "iso" +Lettertekens worden omgezet tussen een \s-1DOS\s0 lettertekenreeks (codetabel) en \s-1ISO\s0 +lettertekenreeks \s-1ISO\-8859\-1\s0 op Unix. \s-1DOS\s0 lettertekens zonder gelijkwaardig +\&\s-1ISO\-8859\-1\s0 teken, waarvoor geen omzetting mogelijk is, worden omgezet in een +punt. Het zelfde geldt voor \s-1ISO\-8859\-1\s0 tekens zonder \s-1DOS\s0 tegenhanger. +.Sp +Wanneer alleen optie \f(CW\*(C`\-iso\*(C'\fR gebruikt wordt, zal dos2unix proberen de actieve +codetabel te gebruiken. Als dat niet mogelijk is wordt codetabel \s-1CP437\s0 +gebruikt, die met name in de \s-1VS\s0 gebruikt word. Om een bepaalde codetabel te +forceren gebruik opties \f(CW\*(C`\-850\*(C'\fR (West-Europees), \f(CW\*(C`\-860\*(C'\fR (Portugees), \f(CW\*(C`\-863\*(C'\fR +(Canadees Frans) of \f(CW\*(C`\-865\*(C'\fR (Scandinavisch). Windows codetabel \s-1CP1252 +\&\s0(West-Europees) wordt ook ondersteund met optie \f(CW\*(C`\-1252\*(C'\fR. Gebruik voor andere +codetabellen dos2unix in combinatie met \fIiconv\fR\|(1). Iconv kan omzetten tussen een +lange lijst letterteken-coderingen. +.Sp +Gebruik \s-1ISO\s0 conversie nooit op Unicode tekst bestanden. Het zal \s-1UTF\-8\s0 +gecodeerde bestanden beschadigen. +.Sp +Enkele voorbeelden: +.Sp +Omzetten van \s-1DOS\s0 standaard codetabel naar Unix Latin\-1 +.Sp +.Vb 1 +\& dos2unix \-iso \-n in.txt uit.txt +.Ve +.Sp +Omzetten van \s-1DOS CP850\s0 naar Unix Latin\-1 +.Sp +.Vb 1 +\& dos2unix \-850 \-n in.txt uit.txt +.Ve +.Sp +Omzetten van Windows \s-1CP1252\s0 naar Unix Latin\-1 +.Sp +.Vb 1 +\& dos2unix \-1252 \-n in.txt uit.txt +.Ve +.Sp +Omzetten van Windows \s-1CP1252\s0 naar Unix \s-1UTF\-8 \s0(Unicode) +.Sp +.Vb 1 +\& iconv \-f CP1252 \-t UTF\-8 in.txt | dos2unix > uit.txt +.Ve +.Sp +Omzetten van Unix Latin\-1 naar \s-1DOS\s0 standaard code tabel +.Sp +.Vb 1 +\& unix2dos \-iso \-n in.txt uit.txt +.Ve +.Sp +Omzetten van Unix Latin\-1 naar \s-1DOS CP850\s0 +.Sp +.Vb 1 +\& unix2dos \-850 \-n in.txt uit.txt +.Ve +.Sp +Omzetten van Unix Latin\-1 naar Windows \s-1CP1252\s0 +.Sp +.Vb 1 +\& unix2dos \-1252 \-n in.txt uit.txt +.Ve +.Sp +Omzetten van Unix \s-1UTF\-8 \s0(Unicode) naar Windows \s-1CP1252\s0 +.Sp +.Vb 1 +\& unix2dos < in.txt | iconv \-f UTF\-8 \-t CP1252 > uit.txt +.Ve +.Sp +Zie ook +en . +.SH "UNICODE" +.IX Header "UNICODE" +.SS "Coderingen" +.IX Subsection "Coderingen" +Er bestaan verschillende Unicode coderingen. Op Unix en Linux zijn Unicode +bestanden typisch gecodeerd in \s-1UTF\-8.\s0 Op Windows kunnen Unicode tekst bestanden +gecodeerd zijn in \s-1UTF\-8, UTF\-16\s0 of \s-1UTF\-16\s0 big endian, maar meestal zijn ze +gecodeerd in \s-1UTF\-16\s0 formaat. +.SS "Conversie" +.IX Subsection "Conversie" +Unicode tekst bestanden kunnen \s-1DOS,\s0 Unix of Mac regeleindes hebben, net +als reguliere tekst bestanden. +.PP +Alle versies van dos2unix en unix2dos kunnen \s-1UTF\-8\s0 gecodeerde bestanden +omzetten, want \s-1UTF\-8\s0 is ontworpen op compatibiliteit met \s-1ASCII.\s0 +.PP +Dos2unix en unix2dos met Unicode \s-1UTF\-16\s0 ondersteuning, kunnen little en big +endian \s-1UTF\-16\s0 gecodeerde tekst bestanden lezen. Om er achter te komen of +dos2unix gebouwd is met \s-1UTF\-16\s0 ondersteuning type \f(CW\*(C`dos2unix \-V\*(C'\fR. +.PP +De Windows versies van dos2unix en unix2dos converteren \s-1UTF\-16\s0 gecodeerde +bestanden altijd naar \s-1UTF\-8\s0 gecondeerde bestanden. Unix versies van +dos2unix/unix2dos zetten \s-1UTF\-16\s0 gecodeerde bestanden om naar de lokale +karakter codering als die gelijk is aan \s-1UTF\-8.\s0 Gebruik de opdracht +\&\fIlocale\fR\|(1) om uit te vinden wat de lokale karakter codering is. +.PP +Omdat \s-1UTF\-8\s0 geformateerde tekstbestanden zowel op Windows en Unix goed +ondersteund worden, hebben dos2unix en unix2dos geen optie om \s-1UTF\-16\s0 bestanden +te schrijven. Alle \s-1UTF\-16\s0 karakters kunnen worden omgezet naar \s-1UTF\-8.\s0 De +omzetting van \s-1UTF\-16\s0 naar \s-1UTF\-8\s0 is verliesvrij. Op Unix worden \s-1UTF\-16\s0 bestanden +overgeslagen als de locale karakter codering ongelijk is aan \s-1UTF\-8,\s0 om te +voorkomen dat er per ongeluk tekst verloren gaat. Wanneer een \s-1UTF\-16\s0 naar +\&\s-1UTF\-8\s0 conversiefout optreedt, bijvoorbeeld wanneer het \s-1UTF\-16\s0 invoerbestand +een fout bevat, wordt het bestand overgeslagen. +.PP +\&\s-1ISO\s0 en 7\-bit conversie werkt niet op \s-1UTF\-16\s0 bestanden. +.SS "Byte Order Mark" +.IX Subsection "Byte Order Mark" +Op Windows hebben Unicode tekstbestanden typisch een Byte Order Mark (\s-1BOM\s0), +omdat veel Windows programma's (inclusief Kladblok) standaard een \s-1BOM\s0 +toevoegen. Zie ook . +.PP +Op Unix hebben Unicode tekstbestanden typisch geen \s-1BOM.\s0 Er wordt aangenomen +dat de codering van tekstbestanden gelijk is aan de lokale karakter +codering. +.PP +Dos2unix kan alleen detecteren of een bestand in \s-1UTF\-16\s0 formaat is als het +bestand een \s-1BOM\s0 heeft. Wanneer een \s-1UTF\-16\s0 bestand geen \s-1BOM\s0 heeft, ziet +dos2unix het bestand als een binair bestand. +.PP +Gebruik dos2unix in combinatie met \fIiconv\fR\|(1) om een \s-1UTF\-16\s0 bestand zonder \s-1BOM\s0 om +te zetten. +.PP +Dos2unix schrijft nooit een \s-1BOM\s0 in het uitvoerbestand, tenzij optie \f(CW\*(C`\-m\*(C'\fR +gebruikt wordt. +.PP +Unix2dos schrijft een \s-1BOM\s0 in het uitvoerbestand wanneer het invoerbestand +een \s-1BOM\s0 heeft, of wanneer optie \f(CW\*(C`\-m\*(C'\fR gebruikt is. +.SS "Unicode voorbeelden" +.IX Subsection "Unicode voorbeelden" +Omzetten van Windows \s-1UTF\-16 \s0(met \s-1BOM\s0) naar Unix \s-1UTF\-8\s0 +.PP +.Vb 1 +\& dos2unix \-n in.txt uit.txt +.Ve +.PP +Omzetten van Windows \s-1UTF\-16 \s0(zonder \s-1BOM\s0) naar Unix \s-1UTF\-8\s0 +.PP +.Vb 1 +\& iconv \-f UTF\-16 \-t UTF\-8 in.txt | dos2unix > uit.txt +.Ve +.PP +Omzetten van Unix \s-1UTF\-8\s0 naar Windows \s-1UTF\-8\s0 met \s-1BOM\s0 +.PP +.Vb 1 +\& unix2dos \-m \-n in.txt uit.txt +.Ve +.PP +Omzetten van Unix \s-1UTF\-8\s0 naar Windows \s-1UTF\-16\s0 +.PP +.Vb 1 +\& unix2dos < in.txt | iconv \-f UTF\-8 \-t UTF\-16 > uit.txt +.Ve +.SH "VOORBEELDEN" +.IX Header "VOORBEELDEN" +Lees invoer van 'stdin' en schrijf uitvoer naar 'stdout'. +.PP +.Vb 2 +\& dos2unix +\& dos2unix \-l \-c mac +.Ve +.PP +Omzetten en vervangen a.txt. Omzetten en vervangen b.txt. +.PP +.Vb 2 +\& dos2unix a.txt b.txt +\& dos2unix \-o a.txt b.txt +.Ve +.PP +Omzetten en vervangen a.txt in ascii conversiemodus. +.PP +.Vb 1 +\& dos2unix a.txt +.Ve +.PP +Omzetten en vervangen a.txt in ascii conversiemodus. +Omzetten en vervangen b.txt in 7bit conversiemodus. +.PP +.Vb 3 +\& dos2unix a.txt \-c 7bit b.txt +\& dos2unix \-c ascii a.txt \-c 7bit b.txt +\& dos2unix \-ascii a.txt \-7 b.txt +.Ve +.PP +Omzetten a.txt van Mac naar Unix format. +.PP +.Vb 2 +\& dos2unix \-c mac a.txt +\& mac2unix a.txt +.Ve +.PP +Omzetten a.txt van Unix naar Mac format. +.PP +.Vb 2 +\& unix2dos \-c mac a.txt +\& unix2mac a.txt +.Ve +.PP +Omzetten en vervangen a.txt met behoud van originele datum. +.PP +.Vb 2 +\& dos2unix \-k a.txt +\& dos2unix \-k \-o a.txt +.Ve +.PP +Omzetten a.txt en schrijf naar e.txt. +.PP +.Vb 1 +\& dos2unix \-n a.txt e.txt +.Ve +.PP +Omzetten a.txt en schrijf naar e.txt, behoud datum e.txt gelijk aan a.txt. +.PP +.Vb 1 +\& dos2unix \-k \-n a.txt e.txt +.Ve +.PP +Omzetten en vervangen a.txt. Omzetten b.txt en schrijf naar e.txt. +.PP +.Vb 2 +\& dos2unix a.txt \-n b.txt e.txt +\& dos2unix \-o a.txt \-n b.txt e.txt +.Ve +.PP +Omzetten c.txt en schrijf naar e.txt. Omzetten en vervangen a.txt. +Omzetten en vervangen b.txt. Omzetten d.txt en schrijf naar f.txt. +.PP +.Vb 1 +\& dos2unix \-n c.txt e.txt \-o a.txt b.txt \-n d.txt f.txt +.Ve +.SH "RECURSIEVE CONVERSIE" +.IX Header "RECURSIEVE CONVERSIE" +Gebruik dos2unix in combinatie met de \fIfind\fR\|(1) en \fIxargs\fR\|(1) opdrachten om +tekstbestanden in een directoryboomstructuur recursief om te zetten. +Bijvoorbeeld om alle .txt bestanden in de directoryboom onder de huidige +map te converteren type: +.PP +.Vb 1 +\& find . \-name *.txt |xargs dos2unix +.Ve +.SH "LOKALISATIE" +.IX Header "LOKALISATIE" +.IP "\fB\s-1LANG\s0\fR" 4 +.IX Item "LANG" +The primaire taal wordt geselecteerd met de omgevingsvariabele \s-1LANG.\s0 De \s-1LANG\s0 +variabele bestaat uit verschillende onderdelen. Het eerste deel is in kleine +letters de taalcode. Het tweede deel is optioneel en is de landcode in +hoofdletters, voorafgegaan door een laag streepje. Er is ook een optioneel +derde deel: lettertekenreeks-codering, voorafgegaan door een punt. Enkele voorbeelden +voor een \s-1POSIX\s0 staandaard shell: +.Sp +.Vb 7 +\& export LANG=nl Nederlands +\& export LANG=nl_NL Nederlands, Nederland +\& export LANG=nl_BE Nederlands, Belgi\[:e] +\& export LANG=es_ES Spaans, Spanje +\& export LANG=es_MX Spaans, Mexico +\& export LANG=en_US.iso88591 Engels, VS, Latin\-1 codering +\& export LANG=en_GB.UTF\-8 Engels, GB, UTF\-8 codering +.Ve +.Sp +Voor een complete lijst van taal\- en landcodes zie de gettext handleiding: + +.Sp +Op Unix systemen kunt u de opdracht \fIlocale\fR\|(1) gebruiken om specifieke +lokalisatie informatie te verkrijgen. +.IP "\fB\s-1LANGUAGE\s0\fR" 4 +.IX Item "LANGUAGE" +Met de omgevingsvariabele \s-1LANGUAGE\s0 kunt u een prioriteitenlijst specificeren +van talen, gescheiden door dubbele punten. Dos2unix geeft voorkeur aan +\&\s-1LANGUAGE\s0 boven \s-1LANG.\s0 Bijvoorbeeld, eerst Nederlands en dan Duits: \f(CW\*(C`LANGUAGE=nl:de\*(C'\fR. +U moet eerst lokalisatie in werking stellen, met het instellen van \s-1LANG \s0(of \s-1LC_ALL\s0) +in een waarde ongelijk aan \*(L"C\*(R", voordat u een talen prioriteitenlijst kunt +gebruiken via de \s-1LANGUAGE\s0 variabele. Zie ook de gettext handleiding: + +.Sp +Als u een taal kiest die niet beschikbaar is worden de standaard +Engelse berichten gebruikt. +.IP "\fB\s-1DOS2UNIX_LOCALEDIR\s0\fR" 4 +.IX Item "DOS2UNIX_LOCALEDIR" +Met de omgevingsvariabele \s-1DOS2UNIX_LOCALEDIR\s0 kan de \s-1LOCALEDIR\s0 gebruikt tijdens +compilatie worden overstemd. \s-1LOCALEDIR\s0 wordt gebruikt om de taalbestanden te +vinden. De \s-1GNU\s0 staandaard waarde is \f(CW\*(C`/usr/local/share/locale\*(C'\fR. De optie \*(L"\-V\*(R" +laat de gebruikte \s-1LOCALEDIR\s0 zien. +.Sp +Voorbeeld (\s-1POSIX\s0 shell): +.Sp +.Vb 1 +\& export DOS2UNIX_LOCALEDIR=$HOME/share/locale +.Ve +.SH "TERUGGAVE WAARDE" +.IX Header "TERUGGAVE WAARDE" +Bij succes wordt nul terug gegeven. Wanneer een systeemfout optreedt wordt +het laatste systeemfoutnummer terug gegeven. Bij andere fouten wordt 1 terug gegeven. +.PP +De teruggave is altijd nul in de modus stille werking, behalve wanneer verkeerde +opties worden gegeven. +.SH "STANDAARDEN" +.IX Header "STANDAARDEN" + +.PP + +.PP + +.PP + +.SH "AUTEURS" +.IX Header "AUTEURS" +Benjamin Lin \- , +Bernd Johannes Wuebben (mac2unix modus) \- , +Christian Wurll (voeg extra regeleinde toe) \- , +Erwin Waterlander \- +.PP +Project pagina: +.PP +SourceForge pagina: +.PP +Freecode: +.SH "ZIE OOK" +.IX Header "ZIE OOK" +\&\fIfile\fR\|(1) +\&\fIfind\fR\|(1) +\&\fIiconv\fR\|(1) +\&\fIlocale\fR\|(1) +\&\fIxargs\fR\|(1) diff --git a/SOURCES/dos2unix.1 b/SOURCES/dos2unix.1 new file mode 100644 index 0000000..2170bf3 --- /dev/null +++ b/SOURCES/dos2unix.1 @@ -0,0 +1,636 @@ +.\" Automatically generated by Pod::Man 2.27 (Pod::Simple 3.28) +.\" +.\" Standard preamble: +.\" ======================================================================== +.de Sp \" Vertical space (when we can't use .PP) +.if t .sp .5v +.if n .sp +.. +.de Vb \" Begin verbatim text +.ft CW +.nf +.ne \\$1 +.. +.de Ve \" End verbatim text +.ft R +.fi +.. +.\" Set up some character translations and predefined strings. \*(-- will +.\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left +.\" double quote, and \*(R" will give a right double quote. \*(C+ will +.\" give a nicer C++. Capital omega is used to do unbreakable dashes and +.\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, +.\" nothing in troff, for use with C<>. +.tr \(*W- +.ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' +.ie n \{\ +. ds -- \(*W- +. ds PI pi +. if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch +. if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch +. ds L" "" +. ds R" "" +. ds C` "" +. ds C' "" +'br\} +.el\{\ +. ds -- \|\(em\| +. ds PI \(*p +. ds L" `` +. ds R" '' +. ds C` +. ds C' +'br\} +.\" +.\" Escape single quotes in literal strings from groff's Unicode transform. +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" +.\" If the F register is turned on, we'll generate index entries on stderr for +.\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index +.\" entries marked with X<> in POD. Of course, you'll have to process the +.\" output yourself in some meaningful fashion. +.\" +.\" Avoid warning from groff about undefined register 'F'. +.de IX +.. +.nr rF 0 +.if \n(.g .if rF .nr rF 1 +.if (\n(rF:(\n(.g==0)) \{ +. if \nF \{ +. de IX +. tm Index:\\$1\t\\n%\t"\\$2" +.. +. if !\nF==2 \{ +. nr % 0 +. nr F 2 +. \} +. \} +.\} +.rr rF +.\" +.\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2). +.\" Fear. Run. Save yourself. No user-serviceable parts. +. \" fudge factors for nroff and troff +.if n \{\ +. ds #H 0 +. ds #V .8m +. ds #F .3m +. ds #[ \f1 +. ds #] \fP +.\} +.if t \{\ +. ds #H ((1u-(\\\\n(.fu%2u))*.13m) +. ds #V .6m +. ds #F 0 +. ds #[ \& +. ds #] \& +.\} +. \" simple accents for nroff and troff +.if n \{\ +. ds ' \& +. ds ` \& +. ds ^ \& +. ds , \& +. ds ~ ~ +. ds / +.\} +.if t \{\ +. ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u" +. ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u' +. ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u' +. ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u' +. ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u' +. ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u' +.\} +. \" troff and (daisy-wheel) nroff accents +.ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V' +.ds 8 \h'\*(#H'\(*b\h'-\*(#H' +.ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#] +.ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H' +.ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u' +.ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#] +.ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#] +.ds ae a\h'-(\w'a'u*4/10)'e +.ds Ae A\h'-(\w'A'u*4/10)'E +. \" corrections for vroff +.if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u' +.if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u' +. \" for low resolution devices (crt and lpr) +.if \n(.H>23 .if \n(.V>19 \ +\{\ +. ds : e +. ds 8 ss +. ds o a +. ds d- d\h'-1'\(ga +. ds D- D\h'-1'\(hy +. ds th \o'bp' +. ds Th \o'LP' +. ds ae ae +. ds Ae AE +.\} +.rm #[ #] #H #V #F C +.\" ======================================================================== +.\" +.IX Title "dos2unix 1" +.TH dos2unix 1 "2012-09-15" "dos2unix" "2017-03-10" +.\" For nroff, turn off justification. Always turn off hyphenation; it makes +.\" way too many mistakes in technical documents. +.if n .ad l +.nh +.SH "NAME" +dos2unix \- DOS/Mac to Unix and vice versa text file format converter +.SH "SYNOPSIS" +.IX Header "SYNOPSIS" +.Vb 2 +\& dos2unix [options] [FILE ...] [\-n INFILE OUTFILE ...] +\& unix2dos [options] [FILE ...] [\-n INFILE OUTFILE ...] +.Ve +.SH "DESCRIPTION" +.IX Header "DESCRIPTION" +The Dos2unix package includes utilities \f(CW\*(C`dos2unix\*(C'\fR and \f(CW\*(C`unix2dos\*(C'\fR to convert +plain text files in \s-1DOS\s0 or Mac format to Unix format and vice versa. +.PP +In DOS/Windows text files a line break, also known as newline, is a combination +of two characters: a Carriage Return (\s-1CR\s0) followed by a Line Feed (\s-1LF\s0). In Unix +text files a line break is a single character: the Line Feed (\s-1LF\s0). In Mac text +files, prior to Mac \s-1OS X,\s0 a line break was single Carriage Return (\s-1CR\s0) +character. Nowadays Mac \s-1OS\s0 uses Unix style (\s-1LF\s0) line breaks. +.PP +Binary files are automatically skipped, unless conversion is forced. +.PP +Non-regular files, such as directories and FIFOs, are automatically skipped. +.PP +Symbolic links and their targets are by default kept untouched. +Symbolic links can optionally be replaced, or the output can be written +to the symbolic link target. +Symbolic links on Windows are not supported. Windows symbolic links +always replaced, keeping the targets unchanged. +.PP +Dos2unix was modelled after dos2unix under SunOS/Solaris and has similar +conversion modes. +.SH "OPTIONS" +.IX Header "OPTIONS" +.IP "\fB\-\-\fR" 4 +.IX Item "--" +Treat all following options as file names. Use this option if you want to +convert files whose names start with a dash. For instance to convert +a file named \*(L"\-foo\*(R", you can use this command: +.Sp +.Vb 1 +\& dos2unix \-\- \-foo +.Ve +.Sp +Or in new file mode: +.Sp +.Vb 1 +\& dos2unix \-n \-\- \-foo out.txt +.Ve +.IP "\fB\-ascii\fR" 4 +.IX Item "-ascii" +Convert only line breaks. This is the default conversion mode. +.IP "\fB\-iso\fR" 4 +.IX Item "-iso" +Conversion between \s-1DOS\s0 and \s-1ISO\-8859\-1\s0 character set. See also section +\&\s-1CONVERSION MODES.\s0 +.IP "\fB\-1252\fR" 4 +.IX Item "-1252" +Use Windows code page 1252 (Western European). +.IP "\fB\-437\fR" 4 +.IX Item "-437" +Use \s-1DOS\s0 code page 437 (\s-1US\s0). This is the default code page used for \s-1ISO\s0 conversion. +.IP "\fB\-850\fR" 4 +.IX Item "-850" +Use \s-1DOS\s0 code page 850 (Western European). +.IP "\fB\-860\fR" 4 +.IX Item "-860" +Use \s-1DOS\s0 code page 860 (Portuguese). +.IP "\fB\-863\fR" 4 +.IX Item "-863" +Use \s-1DOS\s0 code page 863 (French Canadian). +.IP "\fB\-865\fR" 4 +.IX Item "-865" +Use \s-1DOS\s0 code page 865 (Nordic). +.IP "\fB\-7\fR" 4 +.IX Item "-7" +Convert 8 bit characters to 7 bit space. +.IP "\fB\-c, \-\-convmode \s-1CONVMODE\s0\fR" 4 +.IX Item "-c, --convmode CONVMODE" +Set conversion mode. Where \s-1CONVMODE\s0 is one of: +\&\fIascii\fR, \fI7bit\fR, \fIiso\fR, \fImac\fR +with ascii being the default. +.IP "\fB\-f, \-\-force\fR" 4 +.IX Item "-f, --force" +Force conversion of binary files. +.IP "\fB\-h, \-\-help\fR" 4 +.IX Item "-h, --help" +Display help and exit. +.IP "\fB\-k, \-\-keepdate\fR" 4 +.IX Item "-k, --keepdate" +Keep the date stamp of output file same as input file. +.IP "\fB\-L, \-\-license\fR" 4 +.IX Item "-L, --license" +Display program's license. +.IP "\fB\-l, \-\-newline\fR" 4 +.IX Item "-l, --newline" +Add additional newline. +.Sp +\&\fBdos2unix\fR: Only \s-1DOS\s0 line breaks are changed to two Unix line breaks. +In Mac mode only Mac line breaks are changed to two Unix +line breaks. +.Sp +\&\fBunix2dos\fR: Only Unix line breaks are changed to two \s-1DOS\s0 line breaks. +In Mac mode Unix line breaks are changed to two Mac line breaks. +.IP "\fB\-m, \-\-add\-bom\fR" 4 +.IX Item "-m, --add-bom" +Write an \s-1UTF\-8\s0 Byte Order Mark in the output file. Never use this option when +the output encoding is other than \s-1UTF\-8.\s0 See also section \s-1UNICODE.\s0 +.IP "\fB\-n, \-\-newfile \s-1INFILE OUTFILE ...\s0\fR" 4 +.IX Item "-n, --newfile INFILE OUTFILE ..." +New file mode. Convert file \s-1INFILE\s0 and write output to file \s-1OUTFILE.\s0 +File names must be given in pairs and wildcard names should \fInot\fR be +used or you \fIwill\fR lose your files. +.Sp +The person who starts the conversion in new file (paired) mode will be the owner +of the converted file. The read/write permissions of the new file will be the +permissions of the original file minus the \fIumask\fR\|(1) of the person who runs the +conversion. +.IP "\fB\-o, \-\-oldfile \s-1FILE ...\s0\fR" 4 +.IX Item "-o, --oldfile FILE ..." +Old file mode. Convert file \s-1FILE\s0 and overwrite output to it. The program +defaults to run in this mode. Wildcard names may be used. +.Sp +In old file (in-place) mode the converted file gets the same owner, group, and +read/write permissions as the original file. Also when the file is converted by +another user who has write permissions on the file (e.g. user root). The +conversion will be aborted when it is not possible to preserve the original +values. Change of owner could mean that the original owner is not able to read +the file any more. Change of group could be a security risk, the file could be +made readable for persons for whom it is not intended. Preservation of owner, +group, and read/write permissions is only supported on Unix. +.IP "\fB\-q, \-\-quiet\fR" 4 +.IX Item "-q, --quiet" +Quiet mode. Suppress all warnings and messages. The return value is zero. +Except when wrong command-line options are used. +.IP "\fB\-s, \-\-safe\fR" 4 +.IX Item "-s, --safe" +Skip binary files (default). +.IP "\fB\-F, \-\-follow\-symlink\fR" 4 +.IX Item "-F, --follow-symlink" +Follow symbolic links and convert the targets. +.IP "\fB\-R, \-\-replace\-symlink\fR" 4 +.IX Item "-R, --replace-symlink" +Replace symbolic links with converted files +(original target files remain unchanged). +.IP "\fB\-S, \-\-skip\-symlink\fR" 4 +.IX Item "-S, --skip-symlink" +Keep symbolic links and targets unchanged (default). +.IP "\fB\-V, \-\-version\fR" 4 +.IX Item "-V, --version" +Display version information and exit. +.SH "MAC MODE" +.IX Header "MAC MODE" +In normal mode line breaks are converted from \s-1DOS\s0 to Unix and vice versa. +Mac line breaks are not converted. +.PP +In Mac mode line breaks are converted from Mac to Unix and vice versa. \s-1DOS\s0 +line breaks are not changed. +.PP +To run in Mac mode use the command-line option \f(CW\*(C`\-c mac\*(C'\fR or use the +commands \f(CW\*(C`mac2unix\*(C'\fR or \f(CW\*(C`unix2mac\*(C'\fR. +.SH "CONVERSION MODES" +.IX Header "CONVERSION MODES" +Conversion modes \fIascii\fR, \fI7bit\fR, and \fIiso\fR +are similar to those of dos2unix/unix2dos under SunOS/Solaris. +.IP "\fBascii\fR" 4 +.IX Item "ascii" +In mode \f(CW\*(C`ascii\*(C'\fR only line breaks are converted. This is the default +conversion mode. +.Sp +Although the name of this mode is \s-1ASCII,\s0 which is a 7 bit standard, the +actual mode is 8 bit. Use always this mode when converting Unicode \s-1UTF\-8\s0 +files. +.IP "\fB7bit\fR" 4 +.IX Item "7bit" +In this mode all 8 bit non-ASCII characters (with values from 128 to 255) +are converted to a 7 bit space. +.IP "\fBiso\fR" 4 +.IX Item "iso" +Characters are converted between a \s-1DOS\s0 character set (code page) and \s-1ISO\s0 +character set \s-1ISO\-8859\-1 \s0(Latin\-1) on Unix. \s-1DOS\s0 characters without \s-1ISO\-8859\-1\s0 +equivalent, for which conversion is not possible, are converted to a dot. The +same counts for \s-1ISO\-8859\-1\s0 characters without \s-1DOS\s0 counterpart. +.Sp +When only option \f(CW\*(C`\-iso\*(C'\fR is used dos2unix will try to determine the active code +page. When this is not possible dos2unix will use default code page \s-1CP437,\s0 +which is mainly used in the \s-1USA. \s0 To force a specific code page use options +\&\f(CW\*(C`\-437\*(C'\fR (\s-1US\s0), \f(CW\*(C`\-850\*(C'\fR (Western European), \f(CW\*(C`\-860\*(C'\fR (Portuguese), \f(CW\*(C`\-863\*(C'\fR (French +Canadian), or \f(CW\*(C`\-865\*(C'\fR (Nordic). Windows code page \s-1CP1252 \s0(Western European) is +also supported with option \f(CW\*(C`\-1252\*(C'\fR. For other code pages use dos2unix in +combination with \fIiconv\fR\|(1). Iconv can convert between a long list of character +encodings. +.Sp +Never use \s-1ISO\s0 converion on Unicode text files. It will corrupt \s-1UTF\-8\s0 encoded files. +.Sp +Some examples: +.Sp +Convert from \s-1DOS\s0 default code page to Unix Latin\-1 +.Sp +.Vb 1 +\& dos2unix \-iso \-n in.txt out.txt +.Ve +.Sp +Convert from \s-1DOS CP850\s0 to Unix Latin\-1 +.Sp +.Vb 1 +\& dos2unix \-850 \-n in.txt out.txt +.Ve +.Sp +Convert from Windows \s-1CP1252\s0 to Unix Latin\-1 +.Sp +.Vb 1 +\& dos2unix \-1252 \-n in.txt out.txt +.Ve +.Sp +Convert from Windows \s-1CP1252\s0 to Unix \s-1UTF\-8 \s0(Unicode) +.Sp +.Vb 1 +\& iconv \-f CP1252 \-t UTF\-8 in.txt | dos2unix > out.txt +.Ve +.Sp +Convert from Unix Latin\-1 to \s-1DOS\s0 default code page. +.Sp +.Vb 1 +\& unix2dos \-iso \-n in.txt out.txt +.Ve +.Sp +Convert from Unix Latin\-1 to \s-1DOS CP850\s0 +.Sp +.Vb 1 +\& unix2dos \-850 \-n in.txt out.txt +.Ve +.Sp +Convert from Unix Latin\-1 to Windows \s-1CP1252\s0 +.Sp +.Vb 1 +\& unix2dos \-1252 \-n in.txt out.txt +.Ve +.Sp +Convert from Unix \s-1UTF\-8 \s0(Unicode) to Windows \s-1CP1252\s0 +.Sp +.Vb 1 +\& unix2dos < in.txt | iconv \-f UTF\-8 \-t CP1252 > out.txt +.Ve +.Sp +See also +and . +.SH "UNICODE" +.IX Header "UNICODE" +.SS "Encodings" +.IX Subsection "Encodings" +There exist different Unicode encodings. On Unix and Linux Unicode files are +typically encoded in \s-1UTF\-8\s0 encoding. On Windows Unicode text files can be +encoded in \s-1UTF\-8, UTF\-16,\s0 or \s-1UTF\-16\s0 big endian, but are mostly encoded in +\&\s-1UTF\-16\s0 format. +.SS "Conversion" +.IX Subsection "Conversion" +Unicode text files can have \s-1DOS,\s0 Unix or Mac line breaks, like regular text +files. +.PP +All versions of dos2unix and unix2dos can convert \s-1UTF\-8\s0 encoded files, because +\&\s-1UTF\-8\s0 was designed for backward compatiblity with \s-1ASCII.\s0 +.PP +Dos2unix and unix2dos with Unicode \s-1UTF\-16\s0 support, can read little and big +endian \s-1UTF\-16\s0 encoded text files. To see if dos2unix was built with \s-1UTF\-16\s0 +support type \f(CW\*(C`dos2unix \-V\*(C'\fR. +.PP +The Windows versions of dos2unix and unix2dos convert \s-1UTF\-16\s0 encoded files +always to \s-1UTF\-8\s0 encoded files. Unix versions of dos2unix/unix2dos convert +\&\s-1UTF\-16\s0 encoded files to the locale character encoding when it is set to \s-1UTF\-8.\s0 +Use the \fIlocale\fR\|(1) command to find out what the locale character encoding is. +.PP +Because \s-1UTF\-8\s0 formatted text files are well supported on both Windows and Unix, +dos2unix and unix2dos have no option to write \s-1UTF\-16\s0 files. All \s-1UTF\-16\s0 +characters can be encoded in \s-1UTF\-8.\s0 Conversion from \s-1UTF\-16\s0 to \s-1UTF\-8\s0 is without +loss. \s-1UTF\-16\s0 files will be skipped on Unix when the locale character encoding +is not \s-1UTF\-8,\s0 to prevent accidental loss of text. When an \s-1UTF\-16\s0 to \s-1UTF\-8\s0 +conversion error occurs, for instance when the \s-1UTF\-16\s0 input file contains +an error, the file will be skipped. +.PP +\&\s-1ISO\s0 and 7\-bit mode conversion do not work on \s-1UTF\-16\s0 files. +.SS "Byte Order Mark" +.IX Subsection "Byte Order Mark" +On Windows Unicode text files typically have a Byte Order Mark (\s-1BOM\s0), because +many Windows programs (including Notepad) add BOMs by default. See also +. +.PP +On Unix Unicode files typically don't have a \s-1BOM.\s0 It is assumed that text files +are encoded in the locale character encoding. +.PP +Dos2unix can only detect if a file is in \s-1UTF\-16\s0 format if the file has a \s-1BOM.\s0 +When an \s-1UTF\-16\s0 file doesn't have a \s-1BOM,\s0 dos2unix will see the file as a binary +file. +.PP +Use dos2unix in combination with \fIiconv\fR\|(1) to convert an \s-1UTF\-16\s0 file without +\&\s-1BOM.\s0 +.PP +Dos2unix never writes a \s-1BOM\s0 in the output file, unless you use option \f(CW\*(C`\-m\*(C'\fR. +.PP +Unix2dos writes a \s-1BOM\s0 in the output file when the input file has a \s-1BOM,\s0 or +when option \f(CW\*(C`\-m\*(C'\fR is used. +.SS "Unicode examples" +.IX Subsection "Unicode examples" +Convert from Windows \s-1UTF\-16 \s0(with \s-1BOM\s0) to Unix \s-1UTF\-8\s0 +.PP +.Vb 1 +\& dos2unix \-n in.txt out.txt +.Ve +.PP +Convert from Windows \s-1UTF\-16 \s0(without \s-1BOM\s0) to Unix \s-1UTF\-8\s0 +.PP +.Vb 1 +\& iconv \-f UTF\-16 \-t UTF\-8 in.txt | dos2unix > out.txt +.Ve +.PP +Convert from Unix \s-1UTF\-8\s0 to Windows \s-1UTF\-8\s0 with \s-1BOM\s0 +.PP +.Vb 1 +\& unix2dos \-m \-n in.txt out.txt +.Ve +.PP +Convert from Unix \s-1UTF\-8\s0 to Windows \s-1UTF\-16\s0 +.PP +.Vb 1 +\& unix2dos < in.txt | iconv \-f UTF\-8 \-t UTF\-16 > out.txt +.Ve +.SH "EXAMPLES" +.IX Header "EXAMPLES" +Read input from 'stdin' and write output to 'stdout'. +.PP +.Vb 2 +\& dos2unix +\& dos2unix \-l \-c mac +.Ve +.PP +Convert and replace a.txt. Convert and replace b.txt. +.PP +.Vb 2 +\& dos2unix a.txt b.txt +\& dos2unix \-o a.txt b.txt +.Ve +.PP +Convert and replace a.txt in ascii conversion mode. +.PP +.Vb 1 +\& dos2unix a.txt +.Ve +.PP +Convert and replace a.txt in ascii conversion mode. +Convert and replace b.txt in 7bit conversion mode. +.PP +.Vb 3 +\& dos2unix a.txt \-c 7bit b.txt +\& dos2unix \-c ascii a.txt \-c 7bit b.txt +\& dos2unix \-ascii a.txt \-7 b.txt +.Ve +.PP +Convert a.txt from Mac to Unix format. +.PP +.Vb 2 +\& dos2unix \-c mac a.txt +\& mac2unix a.txt +.Ve +.PP +Convert a.txt from Unix to Mac format. +.PP +.Vb 2 +\& unix2dos \-c mac a.txt +\& unix2mac a.txt +.Ve +.PP +Convert and replace a.txt while keeping original date stamp. +.PP +.Vb 2 +\& dos2unix \-k a.txt +\& dos2unix \-k \-o a.txt +.Ve +.PP +Convert a.txt and write to e.txt. +.PP +.Vb 1 +\& dos2unix \-n a.txt e.txt +.Ve +.PP +Convert a.txt and write to e.txt, keep date stamp of e.txt same as a.txt. +.PP +.Vb 1 +\& dos2unix \-k \-n a.txt e.txt +.Ve +.PP +Convert and replace a.txt. Convert b.txt and write to e.txt. +.PP +.Vb 2 +\& dos2unix a.txt \-n b.txt e.txt +\& dos2unix \-o a.txt \-n b.txt e.txt +.Ve +.PP +Convert c.txt and write to e.txt. Convert and replace a.txt. +Convert and replace b.txt. Convert d.txt and write to f.txt. +.PP +.Vb 1 +\& dos2unix \-n c.txt e.txt \-o a.txt b.txt \-n d.txt f.txt +.Ve +.SH "RECURSIVE CONVERSION" +.IX Header "RECURSIVE CONVERSION" +Use dos2unix in combination with the \fIfind\fR\|(1) and \fIxargs\fR\|(1) commands to +recursively convert text files in a directory tree structure. For instance to +convert all .txt files in the directory tree under the current directory type: +.PP +.Vb 1 +\& find . \-name *.txt |xargs dos2unix +.Ve +.SH "LOCALIZATION" +.IX Header "LOCALIZATION" +.IP "\fB\s-1LANG\s0\fR" 4 +.IX Item "LANG" +The primary language is selected with the environment variable \s-1LANG.\s0 The \s-1LANG\s0 +variable consists out of several parts. The first part is in small letters the +language code. The second is optional and is the country code in capital +letters, preceded with an underscore. There is also an optional third part: +character encoding, preceded with a dot. A few examples for \s-1POSIX\s0 standard type +shells: +.Sp +.Vb 7 +\& export LANG=nl Dutch +\& export LANG=nl_NL Dutch, The Netherlands +\& export LANG=nl_BE Dutch, Belgium +\& export LANG=es_ES Spanish, Spain +\& export LANG=es_MX Spanish, Mexico +\& export LANG=en_US.iso88591 English, USA, Latin\-1 encoding +\& export LANG=en_GB.UTF\-8 English, UK, UTF\-8 encoding +.Ve +.Sp +For a complete list of language and country codes see the gettext manual: + +.Sp +On Unix systems you can use to command \fIlocale\fR\|(1) to get locale specific +information. +.IP "\fB\s-1LANGUAGE\s0\fR" 4 +.IX Item "LANGUAGE" +With the \s-1LANGUAGE\s0 environment variable you can specify a priority list of +languages, separated by colons. Dos2unix gives preference to \s-1LANGUAGE\s0 over \s-1LANG.\s0 +For instance, first Dutch and then German: \f(CW\*(C`LANGUAGE=nl:de\*(C'\fR. You have to first +enable localization, by setting \s-1LANG \s0(or \s-1LC_ALL\s0) to a value other than +\&\*(L"C\*(R", before you can use a language priority list through the \s-1LANGUAGE\s0 +variable. See also the gettext manual: + +.Sp +If you select a language which is not available you will get the +standard English messages. +.IP "\fB\s-1DOS2UNIX_LOCALEDIR\s0\fR" 4 +.IX Item "DOS2UNIX_LOCALEDIR" +With the environment variable \s-1DOS2UNIX_LOCALEDIR\s0 the \s-1LOCALEDIR\s0 set +during compilation can be overruled. \s-1LOCALEDIR\s0 is used to find the +language files. The \s-1GNU\s0 default value is \f(CW\*(C`/usr/local/share/locale\*(C'\fR. +Option \fB\-\-version\fR will display the \s-1LOCALEDIR\s0 that is used. +.Sp +Example (\s-1POSIX\s0 shell): +.Sp +.Vb 1 +\& export DOS2UNIX_LOCALEDIR=$HOME/share/locale +.Ve +.SH "RETURN VALUE" +.IX Header "RETURN VALUE" +On success, zero is returned. When a system error occurs the last system error will be +returned. For other errors 1 is returned. +.PP +The return value is always zero in quiet mode, except when wrong command-line options +are used. +.SH "STANDARDS" +.IX Header "STANDARDS" + +.PP + +.PP + +.PP + +.SH "AUTHORS" +.IX Header "AUTHORS" +Benjamin Lin \- +Bernd Johannes Wuebben (mac2unix mode) \- , +Christian Wurll (add extra newline) \- , +Erwin Waterlander \- (Maintainer) +.PP +Project page: +.PP +SourceForge page: +.PP +Freecode: +.SH "SEE ALSO" +.IX Header "SEE ALSO" +\&\fIfile\fR\|(1) +\&\fIfind\fR\|(1) +\&\fIiconv\fR\|(1) +\&\fIlocale\fR\|(1) +\&\fIxargs\fR\|(1) diff --git a/SPECS/dos2unix.spec b/SPECS/dos2unix.spec new file mode 100644 index 0000000..d2f0324 --- /dev/null +++ b/SPECS/dos2unix.spec @@ -0,0 +1,265 @@ +Summary: Text file format converters +Name: dos2unix +Version: 6.0.3 +Release: 7%{?dist} +Group: Applications/Text +License: BSD +URL: http://waterlan.home.xs4all.nl/dos2unix.html +Source: http://waterlan.home.xs4all.nl/dos2unix/%{name}-%{version}.tar.gz +Source1: dos2unix.1 +Source2: dos2unix-es.1 +Source3: dos2unix-nl.1 +BuildRequires: gettext +BuildRequires: perl-Pod-Checker +Provides: unix2dos = %{version}-%{release} +Obsoletes: unix2dos < 5.1-1 + +%description +Convert text files with DOS or Mac line endings to Unix line endings and +vice versa. + +%prep +%setup -q + +%build +make %{?_smp_mflags} + +%install +make DESTDIR=$RPM_BUILD_ROOT install + +install -m 644 %{SOURCE1} $RPM_BUILD_ROOT/%{_mandir}/man1/dos2unix.1 +install -m 644 %{SOURCE2} $RPM_BUILD_ROOT/%{_mandir}/es/man1/dos2unix.1 +install -m 644 %{SOURCE3} $RPM_BUILD_ROOT/%{_mandir}/nl/man1/dos2unix.1 + +# We add doc files manually to %%doc +rm -rf $RPM_BUILD_ROOT%{_docdir} + +%find_lang %{name} --with-man --all-name + +%files -f %{name}.lang +%defattr(-,root,root,0755) +%doc man/man1/dos2unix.htm ChangeLog.txt COPYING.txt +%doc NEWS.txt README.txt TODO.txt +%{_bindir}/dos2unix +%{_bindir}/mac2unix +%{_bindir}/unix2dos +%{_bindir}/unix2mac +%{_mandir}/man1/*.1* + +%clean +rm -rf $RPM_BUILD_ROOT + +%changelog +* Sun Mar 12 2017 Than Ngo - - 6.0.3-7 +- Resolves: bz#1370965, manpage appears to be truncated + +* Fri Mar 10 2017 Than Ngo - - 6.0.3-6 +- Resolves: bz#1370965, bumpspec release to fix the man page issue + +* Mon Feb 13 2017 Than Ngo - 6.0.3-5 +- Resolves: bz#1370965, manpage appears to be truncated + +* Fri Jan 24 2014 Daniel Mach - 6.0.3-4 +- Mass rebuild 2014-01-24 + +* Fri Dec 27 2013 Daniel Mach - 6.0.3-3 +- Mass rebuild 2013-12-27 + +* Fri Feb 22 2013 Tim Waugh 6.0.3-2 +- Build requires perl-Pod-Checker. +- Fixed bogus changelog dates. + +* Mon Jan 28 2013 Tim Waugh 6.0.3-1 +- 6.0.3. + +* Fri Sep 7 2012 Tim Waugh 6.0.2-1 +- 6.0.2. + +* Thu Jul 26 2012 Tim Waugh 6.0.1-1 +- 6.0.1. + +* Wed Jul 18 2012 Fedora Release Engineering - 6.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild + +* Tue May 8 2012 Tim Waugh 6.0-1 +- 6.0. + +* Tue Mar 13 2012 Tim Waugh 5.3.3-1 +- 5.3.3. + +* Mon Jan 30 2012 Tim Waugh 5.3.2-1 +- 5.3.2. + +* Fri Jan 13 2012 Fedora Release Engineering - 5.3.1-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild + +* Wed Aug 10 2011 Tim Waugh 5.3.1-1 +- 5.3.1. + +* Fri May 20 2011 Tim Waugh 5.3-2 +- No longer requires ghostscript or groff. +- Large file support taken care of upstream now. + +* Wed Apr 27 2011 Tim Waugh 5.3-1 +- 5.3. + +* Mon Apr 11 2011 Tim Waugh 5.2.1-1 +- 5.2.1. + +* Tue Feb 15 2011 Tim Waugh 5.2-3 +- Build requires perl (for pod2man). + +* Tue Feb 08 2011 Fedora Release Engineering - 5.2-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild + +* Tue Feb 1 2011 Tim Waugh 5.2-1 +- Update to 5.2. +- Build requires groff and ghostscript. + +* Thu Aug 19 2010 Chen Lei 5.1.1-1 +- Update to 5.1.1 + +* Wed Aug 18 2010 Tim Waugh 5.1-1 +- Applied changes from Chen Lei (bug #592922): + * Sun Aug 15 2010 Chen Lei 5.1-1 + - 5.1. + - Update spec to match latest guidelines w.r.t buildroot tag + +* Tue Jan 26 2010 Tim Waugh 4.1.2-1 +- 4.1.2. + +* Fri Jan 22 2010 Tim Waugh 4.1.1-1 +- 4.1.1. New upstream. + +* Fri Jul 24 2009 Fedora Release Engineering - 3.1-36 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild + +* Tue Feb 24 2009 Fedora Release Engineering - 3.1-35 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild + +* Wed Sep 24 2008 Tim Waugh 3.1-34 +- Moved 'make clean' to prep section and added comment about there + being no upstream (bug #225706). + +* Mon Sep 8 2008 Tim Waugh 3.1-33 +- Preserve file modes (bug #437465). +- Fixed manpage grammar (bug #460731). + +* Mon Apr 14 2008 Tim Waugh 3.1-32 +- Adjust license tag (bug #225706). +- Fix missing prototype (bug #225706). +- Install copy as symbolic links (bug #225706). + +* Wed Feb 13 2008 Tim Waugh 3.1-31 +- Rebuild for GCC 4.3. + +* Fri Jan 18 2008 Tim Waugh 3.1-30 +- Applied patch from bug #292100 to fix segfault with missing -c argument. + +* Wed Aug 29 2007 Tim Waugh 3.1-29 +- Rebuild. + +* Tue Feb 6 2007 Tim Waugh 3.1-28 +- Fixed build root (bug #225706). +- Build with SMP flags (bug #225706). +- Use dist in release tag (bug #225706). +- Fixed macros in changelog (bug #225706). +- Preserve timestamps when using install (bug #225706). + +* Wed Jul 12 2006 Jesse Keating - 3.1-27.1 +- rebuild + +* Mon Jul 10 2006 Tim Waugh 3.1-27 +- Re-encoded spec file in UTF-8 (bug #197817). + +* Mon Jun 5 2006 Tim Waugh 3.1-26 +- Rebuilt. + +* Thu Jun 1 2006 Tim Waugh 3.1-25 +- Build with large file support. + +* Fri Feb 10 2006 Jesse Keating - 3.1-24.2.1 +- bump again for double-long bug on ppc(64) + +* Tue Feb 07 2006 Jesse Keating - 3.1-24.2 +- rebuilt for new gcc4.1 snapshot and glibc changes + +* Fri Dec 09 2005 Jesse Keating +- rebuilt + +* Wed Apr 13 2005 Tim Waugh 3.1-24 +- Fixed tmppath patch (bug #150277). + +* Thu Mar 3 2005 Mike A. Harris 3.1-23 +- Bump and rebuild for FC4, using gcc 4. + +* Tue Feb 8 2005 Mike A. Harris 3.1-22 +- Bump and rebuild for FC4 + +* Wed Oct 20 2004 Miloslav Trmac - 3.1-21 +- Don't just delete the original file when destination and current directory + are on different filesystems (#65548, #123069, patch by James Antill) +- Fix return type of StripDelimiter in dos2unix-3.1-safeconv.patch (#136148) + +* Wed Oct 6 2004 Mike A. Harris 3.1-20 +- Added dos2unix-3.1-manpage-update-57507.patch to fix manpage (#57507) +- Added dos2unix-3.1-preserve-file-modes.patch to properly preserve file + permissions (#91331,55183,112710,132145) + +* Sun Sep 26 2004 Rik van Riel 3.1-19 +- safer conversion w/ mac2unix (fix from bz #57508) + +* Tue Jun 15 2004 Elliot Lee +- rebuilt + +* Fri Feb 13 2004 Elliot Lee +- rebuilt + +* Wed Jun 04 2003 Elliot Lee +- rebuilt + +* Wed Feb 05 2003 Elliot Lee 3.1-15 +- Remove build dependency on perl, since perl BuildRequires: dos2unix, + and there's no good reason not to just use sed here. + +* Wed Jan 22 2003 Tim Powers +- rebuilt + +* Mon Oct 7 2002 Mike A. Harris 3.1-13 +- All-arch rebuild +- Added BuildRequires: perl + +* Fri Jun 21 2002 Tim Powers +- automated rebuild + +* Thu May 23 2002 Tim Powers +- automated rebuild + +* Thu Feb 28 2002 Trond Eivind Glomsrød 3.1-10 +- Build in new environment + +* Thu Jan 17 2002 Bernhard Rosenkraenzer +- Fix bug #57700 (segfault) +- Add the mac2unix symlink recommended in README +- Fix compiler warnings + +* Wed Jan 09 2002 Tim Powers +- automated rebuild + +* Sun Jun 24 2001 Elliot Lee +- Bump release + rebuild. + +* Wed Jan 10 2001 Bernhard Rosenkraenzer +- shut up rpmlint + +* Fri Nov 17 2000 Tim Powers +- use mkstemp instead of mktemp. Not much needed to change. + +* Thu Nov 16 2000 Tim Powers +- cleaned up specfile a bit +- built for 7.1 + +* Wed Jul 07 1999 Peter Soos +- Added Hungarian "Summary:" and "%%description" +- Corrected the file and directory attributes to rebuild the package + under RedHat Linux 6.0