User Tools

Site Tools


docs:diff:examples

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
docs:diff:examples [2015/09/13 17:38] – oJQvcusVreJYoYAYP 146.185.234.48docs:diff:examples [2015/09/15 05:14] (current) – old revision restored 91.89.129.106
Line 1: Line 1:
-http://nudeslutsonline.tk/#8574 webcam chat nude women slut+====== diff(1) examples ====== 
 + 
 +===== files used ===== 
 + 
 +file a: 
 +<code - a> 
 +01 
 +02 
 +03 
 +04 
 +05 
 +06 
 +07 
 +08 
 +09 
 +10 
 +</code> 
 + 
 +file b ("06" is missing): 
 +<code - b> 
 +01 
 +02 
 +03 
 +04 
 +05 
 +07 
 +08 
 +09 
 +10 
 +</code> 
 + 
 +file c ("06a" inserted): 
 +<code - c> 
 +01 
 +02 
 +03 
 +04 
 +05 
 +06 
 +06a 
 +07 
 +08 
 +09 
 +10 
 +</code> 
 + 
 +file d ("06a" replaces "06"): 
 +<code - d> 
 +01 
 +02 
 +03 
 +04 
 +05 
 +06a 
 +07 
 +08 
 +09 
 +10 
 +</code> 
 + 
 +===== one deleted line ===== 
 + 
 +''diff a b'' 
 +<code> 
 +6d5 
 +< 06 
 +</code> 
 + 
 +''diff -u a b'' 
 +<code> 
 +--- a   2014-04-09 11:59:40.347723727 +0200 
 ++++ b   2014-04-09 11:59:51.651574650 +0200 
 +@@ -3,7 +3,6 @@ 
 + 03 
 + 04 
 + 05 
 +-06 
 + 07 
 + 08 
 + 09 
 +</code> 
 + 
 +''diff -e a b'' 
 +<code> 
 +6d 
 +</code> 
 + 
 +===== one additional line ===== 
 + 
 +''diff a c'' 
 +<code> 
 +6d7 
 +> 06a 
 +</code> 
 + 
 +''diff -u a c'' 
 +<code> 
 +--- a   2014-04-09 11:59:40.347723727 +0200 
 ++++ c   2014-04-09 12:08:41.088672486 +0200 
 +@@ -4,6 +4,7 @@ 
 + 04 
 + 05 
 + 06 
 ++06a 
 + 07 
 + 08 
 + 09 
 +</code> 
 + 
 +''diff -e a c'' 
 +<code> 
 +6a 
 +06a 
 +
 +</code> 
 + 
 + 
 +===== one line changed ===== 
 + 
 +''diff a d'' 
 +<code> 
 +6c6 
 +< 06 
 +--- 
 +> 06a 
 +</code> 
 + 
 +''diff -u a d'' 
 +<code> 
 +--- a   2014-04-09 11:59:40.347723727 +0200 
 ++++ d   2014-04-09 12:12:33.541634228 +0200 
 +@@ -3,7 +3,7 @@ 
 + 03 
 + 04 
 + 05 
 +-06 
 ++06a 
 + 07 
 + 08 
 + 09 
 +</code> 
 + 
 +''diff -e a d'' 
 +<code> 
 +6c 
 +06a 
 +
 +</code> 
 + 
 +===== output of "diff -u" explained ===== 
 + 
 +<HTML> 
 +<pre> 
 +     1 --- <span style="color:red">a</span><span style="background-color:#ffd0d0">   </span><span style="color:red">2014-04-09 11:59:40.347723727 +0200</span> 
 +     2 +++ <span style="color:green">d</span><span style="background-color:#d0ffd0">   </span><span style="color:green">2014-04-09 12:12:33.541634228 +0200</span> 
 +     3 @@ <span style="color:red">-3,7</span> <span style="color:green">+3,7</span> @@ 
 +     4 03 
 +     5 04 
 +     6 05 
 +     7 <span style="color:red">-06</span> 
 +     8 <span style="color:green">+06a</span> 
 +     9 07 
 +    10 08 
 +    11 09 
 +</pre> 
 +</HTML> 
 + 
 +| <html><span style="color:red">a</span></html>   | file name 1 | 
 +| <html><span style="color:green">b</span></html> | file name 2 | 
 +| <html><span style="background-color:#ffd0d0">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span></html> | a TAB char as separator | 
 +| <html><span style="background-color:#d0ffd0">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span></html> | a TAB char as separator | 
 +| <html><span style="color:red">2014-04-09 11:59:40.347723727 +0200</span></html>   | date of file 'a' |  
 +| <html><span style="color:green">2014-04-09 12:12:33.541634228 +0200</span></html> | date of file 'b'
 +| <html>@@ <span style="color:red">-3,7</span> <span style="color:green">+3,7</span> @@</html> | a 'hunk' |  
 +| <html><span style="color:red">-3,7</span></html>   | range of the original file ('a') with '3' representing the starting line number and '7' the number of lines the hunk applies to | 
 +| <html><span style="color:green">+3,7</span></html> | range of the original file ('b') with '3' representing the starting line number and '7' the number of lines the hunk applies to | 
 +| <html><span style="color:red">-06</span></html>    | removed line | 
 +| <html><span style="color:green">+06a</span></html> | added line   | 
 + 
 +===== see also ===== 
 + 
 +  * man diff(1) 
 +  * http://en.wikipedia.org/wiki/Diff 
 + 
docs/diff/examples.1442158682.txt.gz · Last modified: 2015/09/13 17:38 by 146.185.234.48