<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="es">
	<id>http://wiki.cabal.mx/index.php?action=history&amp;feed=atom&amp;title=Comandos_de_la_terminal%2Fdiff</id>
	<title>Comandos de la terminal/diff - Historial de revisiones</title>
	<link rel="self" type="application/atom+xml" href="http://wiki.cabal.mx/index.php?action=history&amp;feed=atom&amp;title=Comandos_de_la_terminal%2Fdiff"/>
	<link rel="alternate" type="text/html" href="http://wiki.cabal.mx/index.php?title=Comandos_de_la_terminal/diff&amp;action=history"/>
	<updated>2026-05-18T07:19:21Z</updated>
	<subtitle>Historial de revisiones para esta página en el wiki</subtitle>
	<generator>MediaWiki 1.32.1</generator>
	<entry>
		<id>http://wiki.cabal.mx/index.php?title=Comandos_de_la_terminal/diff&amp;diff=5339&amp;oldid=prev</id>
		<title>Rrc en 23:08 1 abr 2014</title>
		<link rel="alternate" type="text/html" href="http://wiki.cabal.mx/index.php?title=Comandos_de_la_terminal/diff&amp;diff=5339&amp;oldid=prev"/>
		<updated>2014-04-01T23:08:19Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Página nueva&lt;/b&gt;&lt;/p&gt;&lt;div&gt;__NOTOC__&lt;br /&gt;
* [[:#diff | diff]]&lt;br /&gt;
&lt;br /&gt;
== diff ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ diff diff --help&lt;br /&gt;
Usage: diff [OPTION]... FILES&lt;br /&gt;
Compare FILES line by line.&lt;br /&gt;
&lt;br /&gt;
Mandatory arguments to long options are mandatory for short options too.&lt;br /&gt;
      --normal                  output a normal diff (the default)&lt;br /&gt;
  -q, --brief                   report only when files differ&lt;br /&gt;
  -s, --report-identical-files  report when two files are the same&lt;br /&gt;
  -c, -C NUM, --context[=NUM]   output NUM (default 3) lines of copied context&lt;br /&gt;
  -u, -U NUM, --unified[=NUM]   output NUM (default 3) lines of unified context&lt;br /&gt;
  -e, --ed                      output an ed script&lt;br /&gt;
  -n, --rcs                     output an RCS format diff&lt;br /&gt;
  -y, --side-by-side            output in two columns&lt;br /&gt;
  -W, --width=NUM               output at most NUM (default 130) print columns&lt;br /&gt;
      --left-column             output only the left column of common lines&lt;br /&gt;
      --suppress-common-lines   do not output common lines&lt;br /&gt;
&lt;br /&gt;
  -p, --show-c-function         show which C function each change is in&lt;br /&gt;
  -F, --show-function-line=RE   show the most recent line matching RE&lt;br /&gt;
      --label LABEL             use LABEL instead of file name&lt;br /&gt;
                                  (can be repeated)&lt;br /&gt;
&lt;br /&gt;
  -t, --expand-tabs             expand tabs to spaces in output&lt;br /&gt;
  -T, --initial-tab             make tabs line up by prepending a tab&lt;br /&gt;
      --tabsize=NUM             tab stops every NUM (default 8) print columns&lt;br /&gt;
      --suppress-blank-empty    suppress space or tab before empty output lines&lt;br /&gt;
  -l, --paginate                pass output through &amp;#039;pr&amp;#039; to paginate it&lt;br /&gt;
&lt;br /&gt;
  -r, --recursive                 recursively compare any subdirectories found&lt;br /&gt;
      --no-dereference            don&amp;#039;t follow symbolic links&lt;br /&gt;
  -N, --new-file                  treat absent files as empty&lt;br /&gt;
      --unidirectional-new-file   treat absent first files as empty&lt;br /&gt;
      --ignore-file-name-case     ignore case when comparing file names&lt;br /&gt;
      --no-ignore-file-name-case  consider case when comparing file names&lt;br /&gt;
  -x, --exclude=PAT               exclude files that match PAT&lt;br /&gt;
  -X, --exclude-from=FILE         exclude files that match any pattern in FILE&lt;br /&gt;
  -S, --starting-file=FILE        start with FILE when comparing directories&lt;br /&gt;
      --from-file=FILE1           compare FILE1 to all operands;&lt;br /&gt;
                                    FILE1 can be a directory&lt;br /&gt;
      --to-file=FILE2             compare all operands to FILE2;&lt;br /&gt;
                                    FILE2 can be a directory&lt;br /&gt;
&lt;br /&gt;
  -i, --ignore-case               ignore case differences in file contents&lt;br /&gt;
  -E, --ignore-tab-expansion      ignore changes due to tab expansion&lt;br /&gt;
  -Z, --ignore-trailing-space     ignore white space at line end&lt;br /&gt;
  -b, --ignore-space-change       ignore changes in the amount of white space&lt;br /&gt;
  -w, --ignore-all-space          ignore all white space&lt;br /&gt;
  -B, --ignore-blank-lines        ignore changes where lines are all blank&lt;br /&gt;
  -I, --ignore-matching-lines=RE  ignore changes where all lines match RE&lt;br /&gt;
&lt;br /&gt;
  -a, --text                      treat all files as text&lt;br /&gt;
      --strip-trailing-cr         strip trailing carriage return on input&lt;br /&gt;
&lt;br /&gt;
  -D, --ifdef=NAME                output merged file with &amp;#039;#ifdef NAME&amp;#039; diffs&lt;br /&gt;
      --GTYPE-group-format=GFMT   format GTYPE input groups with GFMT&lt;br /&gt;
      --line-format=LFMT          format all input lines with LFMT&lt;br /&gt;
      --LTYPE-line-format=LFMT    format LTYPE input lines with LFMT&lt;br /&gt;
    These format options provide fine-grained control over the output&lt;br /&gt;
      of diff, generalizing -D/--ifdef.&lt;br /&gt;
    LTYPE is &amp;#039;old&amp;#039;, &amp;#039;new&amp;#039;, or &amp;#039;unchanged&amp;#039;.  GTYPE is LTYPE or &amp;#039;changed&amp;#039;.&lt;br /&gt;
    GFMT (only) may contain:&lt;br /&gt;
      %&amp;lt;  lines from FILE1&lt;br /&gt;
      %&amp;gt;  lines from FILE2&lt;br /&gt;
      %=  lines common to FILE1 and FILE2&lt;br /&gt;
      %[-][WIDTH][.[PREC]]{doxX}LETTER  printf-style spec for LETTER&lt;br /&gt;
        LETTERs are as follows for new group, lower case for old group:&lt;br /&gt;
          F  first line number&lt;br /&gt;
          L  last line number&lt;br /&gt;
          N  number of lines = L-F+1&lt;br /&gt;
          E  F-1&lt;br /&gt;
          M  L+1&lt;br /&gt;
      %(A=B?T:E)  if A equals B then T else E&lt;br /&gt;
    LFMT (only) may contain:&lt;br /&gt;
      %L  contents of line&lt;br /&gt;
      %l  contents of line, excluding any trailing newline&lt;br /&gt;
      %[-][WIDTH][.[PREC]]{doxX}n  printf-style spec for input line number&lt;br /&gt;
    Both GFMT and LFMT may contain:&lt;br /&gt;
      %%  %&lt;br /&gt;
      %c&amp;#039;C&amp;#039;  the single character C&lt;br /&gt;
      %c&amp;#039;\OOO&amp;#039;  the character with octal code OOO&lt;br /&gt;
      C    the character C (other characters represent themselves)&lt;br /&gt;
&lt;br /&gt;
  -d, --minimal            try hard to find a smaller set of changes&lt;br /&gt;
      --horizon-lines=NUM  keep NUM lines of the common prefix and suffix&lt;br /&gt;
      --speed-large-files  assume large files and many scattered small changes&lt;br /&gt;
&lt;br /&gt;
      --help               display this help and exit&lt;br /&gt;
  -v, --version            output version information and exit&lt;br /&gt;
&lt;br /&gt;
FILES are &amp;#039;FILE1 FILE2&amp;#039; or &amp;#039;DIR1 DIR2&amp;#039; or &amp;#039;DIR FILE...&amp;#039; or &amp;#039;FILE... DIR&amp;#039;.&lt;br /&gt;
If --from-file or --to-file is given, there are no restrictions on FILE(s).&lt;br /&gt;
If a FILE is &amp;#039;-&amp;#039;, read standard input.&lt;br /&gt;
Exit status is 0 if inputs are the same, 1 if different, 2 if trouble.&lt;br /&gt;
&lt;br /&gt;
Report bugs to: bug-diffutils@gnu.org&lt;br /&gt;
Report Mageia bugs to: https://bugs.mageia.org&lt;br /&gt;
GNU diffutils home page: &amp;lt;http://www.gnu.org/software/diffutils/&amp;gt;&lt;br /&gt;
General help using GNU software: &amp;lt;http://www.gnu.org/gethelp/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ diff --version&lt;br /&gt;
diff (GNU diffutils) 3.3&lt;br /&gt;
Packaged by Mageia&lt;br /&gt;
Copyright (C) 2013 Free Software Foundation, Inc.&lt;br /&gt;
License GPLv3+: GNU GPL version 3 or later &amp;lt;http://gnu.org/licenses/gpl.html&amp;gt;.&lt;br /&gt;
This is free software: you are free to change and redistribute it.&lt;br /&gt;
There is NO WARRANTY, to the extent permitted by law.&lt;br /&gt;
&lt;br /&gt;
Written by Paul Eggert, Mike Haertel, David Hayes,&lt;br /&gt;
Richard Stallman, and Len Tower.&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ rpm -qa | grep diff&lt;br /&gt;
diffutils-3.3-2.mga4&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ diff Archivo1 Archivo2&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ diff Archivo1 UniqEjemplo &lt;br /&gt;
0a1,9&lt;br /&gt;
&amp;gt; Uno&lt;br /&gt;
&amp;gt; dos&lt;br /&gt;
&amp;gt; Tres&lt;br /&gt;
&amp;gt; Dos&lt;br /&gt;
&amp;gt; quatro&lt;br /&gt;
&amp;gt; quatro&lt;br /&gt;
&amp;gt; Quatro&lt;br /&gt;
&amp;gt; uno&lt;br /&gt;
&amp;gt; cinco&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ diff UniqEjemplo Uni&lt;br /&gt;
UniqEjemplo      UniqSortEjemplo  &lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ diff UniqEjemplo UniqSortEjemplo &lt;br /&gt;
1c1&lt;br /&gt;
&amp;lt; Uno&lt;br /&gt;
---&lt;br /&gt;
&amp;gt; cinco&lt;br /&gt;
3d2&lt;br /&gt;
&amp;lt; Tres&lt;br /&gt;
7a7&lt;br /&gt;
&amp;gt; Tres&lt;br /&gt;
9c9&lt;br /&gt;
&amp;lt; cinco&lt;br /&gt;
---&lt;br /&gt;
&amp;gt; Uno&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ cat UniqEjemplo&lt;br /&gt;
Uno&lt;br /&gt;
dos&lt;br /&gt;
Tres&lt;br /&gt;
Dos&lt;br /&gt;
quatro&lt;br /&gt;
quatro&lt;br /&gt;
Quatro&lt;br /&gt;
uno&lt;br /&gt;
cinco&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ cat UniqSortEjemplo&lt;br /&gt;
cinco&lt;br /&gt;
dos&lt;br /&gt;
Dos&lt;br /&gt;
quatro&lt;br /&gt;
quatro&lt;br /&gt;
Quatro&lt;br /&gt;
Tres&lt;br /&gt;
uno&lt;br /&gt;
Uno&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ diff -s Archivo1 Archivo2&lt;br /&gt;
Files Archivo1 and Archivo2 are identical&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ diff -y UniqEjemplo UniqSortEjemplo &lt;br /&gt;
Uno							      |	cinco&lt;br /&gt;
dos								dos&lt;br /&gt;
Tres							      &amp;lt;&lt;br /&gt;
Dos								Dos&lt;br /&gt;
quatro								quatro&lt;br /&gt;
quatro								quatro&lt;br /&gt;
Quatro								Quatro&lt;br /&gt;
							      &amp;gt;	Tres&lt;br /&gt;
uno								uno&lt;br /&gt;
cinco							      |	Uno&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ diff -y  --suppress-common-lines UniqEjemplo UniqSortEjemplo &lt;br /&gt;
Uno							      |	cinco&lt;br /&gt;
Tres							      &amp;lt;&lt;br /&gt;
							      &amp;gt;	Tres&lt;br /&gt;
cinco							      |	Uno&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ diff  UniqEjemploMayusc UniqEjemploMinusc&lt;br /&gt;
1,7c1,7&lt;br /&gt;
&amp;lt; Uno&lt;br /&gt;
&amp;lt; Dos&lt;br /&gt;
&amp;lt; Tres&lt;br /&gt;
&amp;lt; Dos&lt;br /&gt;
&amp;lt; Quatro&lt;br /&gt;
&amp;lt; Uno&lt;br /&gt;
&amp;lt; Cinco&lt;br /&gt;
---&lt;br /&gt;
&amp;gt; uno&lt;br /&gt;
&amp;gt; dos&lt;br /&gt;
&amp;gt; tres&lt;br /&gt;
&amp;gt; dos&lt;br /&gt;
&amp;gt; quatro&lt;br /&gt;
&amp;gt; uno&lt;br /&gt;
&amp;gt; cinco&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ diff -i  UniqEjemploMayusc UniqEjemploMinusc &lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ diff -y  UniqEjemploMayusc UniqEjemploMinusc &lt;br /&gt;
Uno							      |	uno&lt;br /&gt;
Dos							      |	dos&lt;br /&gt;
Tres							      |	tres&lt;br /&gt;
Dos							      |	dos&lt;br /&gt;
Quatro							      |	quatro&lt;br /&gt;
Uno							      |	uno&lt;br /&gt;
Cinco							      |	cinco&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ diff UniqEjemplo UniqEjemploConLineasVacios&lt;br /&gt;
2a3,5&lt;br /&gt;
&amp;gt; &lt;br /&gt;
&amp;gt; &lt;br /&gt;
&amp;gt; &lt;br /&gt;
7a11,13&lt;br /&gt;
&amp;gt; &lt;br /&gt;
&amp;gt; &lt;br /&gt;
&amp;gt; &lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ diff -B UniqEjemplo UniqEjemploConLineasVacios&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ diff -y UniqEjemplo UniqEjemploConLineasVacios&lt;br /&gt;
Uno								Uno&lt;br /&gt;
dos								dos&lt;br /&gt;
							      &amp;gt;&lt;br /&gt;
							      &amp;gt;&lt;br /&gt;
							      &amp;gt;&lt;br /&gt;
Tres								Tres&lt;br /&gt;
Dos								Dos&lt;br /&gt;
quatro								quatro&lt;br /&gt;
quatro								quatro&lt;br /&gt;
Quatro								Quatro&lt;br /&gt;
							      &amp;gt;&lt;br /&gt;
							      &amp;gt;&lt;br /&gt;
							      &amp;gt;&lt;br /&gt;
uno								uno&lt;br /&gt;
cinco								cinco&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ diff UniqEjemplo UniqEjemploConLineasVacios &amp;gt; /dev/null&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ [ $? -eq 0 ] &amp;amp;&amp;amp; echo &amp;quot;Archivos Son Igual&amp;quot; || echo &amp;quot;Archivos Son Diferentes&amp;quot;&lt;br /&gt;
Archivos Son Diferentes&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ diff -B UniqEjemplo UniqEjemploConLineasVacios &amp;gt; /dev/null&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ [ $? -eq 0 ] &amp;amp;&amp;amp; echo &amp;quot;Archivos Son Igual&amp;quot; || echo &amp;quot;Archivos Son Diferentes&amp;quot;&lt;br /&gt;
Archivos Son Igual&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Comandos de la terminal]]&lt;/div&gt;</summary>
		<author><name>Rrc</name></author>
		
	</entry>
</feed>