{"id":2246,"date":"2012-11-04T22:21:41","date_gmt":"2012-11-04T14:21:41","guid":{"rendered":"https:\/\/kyle.ai\/blog\/?p=2246"},"modified":"2012-11-04T22:23:19","modified_gmt":"2012-11-04T14:23:19","slug":"%e8%af%bb%e6%87%82diff","status":"publish","type":"post","link":"https:\/\/kyle.ai\/blog\/2246.html","title":{"rendered":"\u8bfb\u61c2diff"},"content":{"rendered":"<p><span style=\"font-size: small;\">diff\u662fUnix\u7cfb\u7edf\u7684\u4e00\u4e2a\u5f88\u91cd\u8981\u7684\u5de5\u5177\u7a0b\u5e8f\u3002<\/span><\/p>\n<p><span style=\"font-size: small;\">\u5b83\u7528\u6765\u6bd4\u8f83\u4e24\u4e2a\u6587\u672c\u6587\u4ef6\u7684\u5dee\u5f02\uff0c\u662f\u4ee3\u7801\u7248\u672c\u7ba1\u7406\u7684\u57fa\u77f3\u4e4b\u4e00\u3002\u4f60\u5728\u547d\u4ee4\u884c\u4e0b\uff0c\u8f93\u5165\uff1a<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n$ diff &lt;\u53d8\u52a8\u524d\u7684\u6587\u4ef6&gt; &lt;\u53d8\u52a8\u540e\u7684\u6587\u4ef6&gt;\r\n<\/pre>\n<p><span style=\"font-size: small;\">diff\u5c31\u4f1a\u544a\u8bc9\u4f60\uff0c\u8fd9\u4e24\u4e2a\u6587\u4ef6\u6709\u4f55\u5dee\u5f02\u3002\u5b83\u7684\u663e\u793a\u7ed3\u679c\u4e0d\u592a\u597d\u61c2\uff0c\u4e0b\u9762\u6211\u5c31\u6765\u8bf4\u660e\uff0c\u5982\u4f55\u8bfb\u61c2diff\u3002<\/span><\/p>\n<p><a href=\"https:\/\/kyle.ai\/blog\/wp-content\/uploads\/2012\/11\/bg2012082901.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-2248\" title=\"bg2012082901\" src=\"https:\/\/kyle.ai\/blog\/wp-content\/uploads\/2012\/11\/bg2012082901.png\" alt=\"\" width=\"650\" height=\"412\" srcset=\"https:\/\/kyle.ai\/blog\/wp-content\/uploads\/2012\/11\/bg2012082901.png 650w, https:\/\/kyle.ai\/blog\/wp-content\/uploads\/2012\/11\/bg2012082901-300x190.png 300w, https:\/\/kyle.ai\/blog\/wp-content\/uploads\/2012\/11\/bg2012082901-236x150.png 236w\" sizes=\"auto, (max-width: 650px) 100vw, 650px\" \/><\/a><\/p>\n<p><span style=\"font-size: small; color: #ff0000;\">\u4e00\u3001diff\u7684\u4e09\u79cd\u683c\u5f0f<\/span><\/p>\n<p><span style=\"font-size: small;\">\u7531\u4e8e\u5386\u53f2\u539f\u56e0\uff0cdiff\u6709\u4e09\u79cd\u683c\u5f0f\uff1a<\/span><\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n* \u6b63\u5e38\u683c\u5f0f\uff08normal diff\uff09\r\n* \u4e0a\u4e0b\u6587\u683c\u5f0f\uff08context diff\uff09\r\n* \u5408\u5e76\u683c\u5f0f\uff08unified diff\uff09\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u6211\u4eec\u4f9d\u6b21\u6765\u770b\u3002<\/span><\/p>\n<p><span style=\"font-size: small; color: #ff0000;\">\u4e8c\u3001\u793a\u4f8b\u6587\u4ef6<\/span><\/p>\n<p><span style=\"font-size: small;\">\u4e3a\u4e86\u4fbf\u4e8e\u8bb2\u89e3\uff0c\u5148\u65b0\u5efa\u4e24\u4e2a\u793a\u4f8b\u6587\u4ef6\u3002<\/span><br \/>\n<span style=\"font-size: small;\"> \u7b2c\u4e00\u4e2a\u6587\u4ef6\u53eb\u505af1\uff0c\u5185\u5bb9\u662f\u6bcf\u884c\u4e00\u4e2aa\uff0c\u4e00\u51717\u884c\u3002<\/span><\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\na\r\na\r\na\r\na\r\na\r\na\r\na\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u7b2c\u4e8c\u4e2a\u6587\u4ef6\u53eb\u505af2\uff0c\u4fee\u6539f1\u800c\u6210\uff0c\u7b2c4\u884c\u53d8\u6210b\uff0c\u5176\u4ed6\u4e0d\u53d8\u3002<\/span><\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\na\r\na\r\na\r\nb\r\na\r\na\r\na\r\n<\/pre>\n<p><span style=\"color: #ff0000; font-size: small;\">\u4e09\u3001\u6b63\u5e38\u683c\u5f0f\u7684diff<\/span><\/p>\n<p><span style=\"font-size: small;\">\u73b0\u5728\u5bf9f1\u548cf2\u8fdb\u884c\u6bd4\u8f83\uff1a<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n$ diff f1 f2\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u8fd9\u65f6\uff0cdiff\u5c31\u4f1a\u663e\u793a\u6b63\u5e38\u683c\u5f0f\u7684\u7ed3\u679c\uff1a<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n4c4\r\n&lt; a\r\n---\r\n&gt; b\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u7b2c\u4e00\u884c\u662f\u4e00\u4e2a\u63d0\u793a\uff0c\u7528\u6765\u8bf4\u660e\u53d8\u52a8\u4f4d\u7f6e\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n\r\n4c4\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u5b83\u5206\u6210\u4e09\u4e2a\u90e8\u5206\uff1a\u524d\u9762\u7684&#8221;4&#8243;\uff0c\u8868\u793af1\u7684\u7b2c4\u884c\u6709\u53d8\u5316\uff1b\u4e2d\u95f4\u7684&#8221;c&#8221;\u8868\u793a\u53d8\u52a8\u7684\u6a21\u5f0f\u662f\u5185\u5bb9\u6539\u53d8\uff08change\uff09\uff0c\u5176\u4ed6\u6a21\u5f0f\u8fd8\u6709&#8221;\u589e\u52a0&#8221;\uff08a\uff0c\u4ee3\u8868addition\uff09\u548c&#8221;\u5220\u9664&#8221;\uff08d\uff0c\u4ee3\u8868deletion\uff09\uff1b\u540e\u9762\u7684&#8221;4&#8243;\uff0c\u8868\u793a\u53d8\u52a8\u540e\u53d8\u6210f2\u7684\u7b2c4\u884c\u3002<\/span><br \/>\n<span style=\"font-size: small;\"> \u7b2c\u4e8c\u884c\u5206\u6210\u4e24\u4e2a\u90e8\u5206\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n&lt; a\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u524d\u9762\u7684\u5c0f\u4e8e\u53f7\uff0c\u8868\u793a\u8981\u4ecef1\u5f53\u4e2d\u53bb\u9664\u8be5\u884c\uff08\u4e5f\u5c31\u662f\u7b2c4\u884c\uff09\uff0c\u540e\u9762\u7684&#8221;a&#8221;\u8868\u793a\u8be5\u884c\u7684\u5185\u5bb9\u3002<\/span><br \/>\n<span style=\"font-size: small;\"> \u7b2c\u4e09\u884c\u7528\u6765\u5206\u5272f1\u548cf2\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n---\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u7b2c\u56db\u884c\uff0c\u7c7b\u4f3c\u4e8e\u7b2c\u4e8c\u884c\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n&gt; b\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u524d\u9762\u7684\u5927\u4e8e\u53f7\u8868\u793af2\u589e\u52a0\u4e86\u8be5\u884c\uff0c\u540e\u9762\u7684&#8221;b&#8221;\u8868\u793a\u8be5\u884c\u7684\u5185\u5bb9\u3002<\/span><br \/>\n<span style=\"font-size: small;\"> \u6700\u65e9\u7684Unix\uff08\u5373AT&amp;T\u7248\u672c\u7684Unix\uff09\uff0c\u4f7f\u7528\u7684\u5c31\u662f\u8fd9\u79cd\u683c\u5f0f\u7684diff\u3002<\/span><\/p>\n<p><span style=\"font-size: small; color: #ff0000;\">\u56db\u3001\u4e0a\u4e0b\u6587\u683c\u5f0f\u7684diff<\/span><\/p>\n<p><span style=\"font-size: small;\">\u4e0a\u4e2a\u4e16\u7eaa80\u5e74\u4ee3\u521d\uff0c\u52a0\u5dde\u5927\u5b66\u4f2f\u514b\u5229\u5206\u6821\u63a8\u51faBSD\u7248\u672c\u7684Unix\u65f6\uff0c\u89c9\u5f97diff\u7684\u663e\u793a\u7ed3\u679c\u592a\u7b80\u5355\uff0c\u6700\u597d\u52a0\u5165\u4e0a\u4e0b\u6587\uff0c\u4fbf\u4e8e\u4e86\u89e3\u53d1\u751f\u7684\u53d8\u52a8\u3002\u56e0\u6b64\uff0c\u63a8\u51fa\u4e86\u4e0a\u4e0b\u6587\u683c\u5f0f\u7684diff\u3002<\/span><br \/>\n<span style=\"font-size: small;\"> \u5b83\u7684\u4f7f\u7528\u65b9\u6cd5\u662f\u52a0\u5165c\u53c2\u6570\uff08\u4ee3\u8868context\uff09\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n$ diff -c f1 f2\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u663e\u793a\u7ed3\u679c\u5982\u4e0b\uff1a<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n*** f1\t2012-08-29 16:45:41.000000000 +0800\r\n--- f2\t2012-08-29 16:45:51.000000000 +0800\r\n***************\r\n*** 1,7 ****\r\na\r\na\r\na\r\n!a\r\na\r\na\r\na\r\n--- 1,7 ----\r\na\r\na\r\na\r\n!b\r\na\r\na\r\na\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u8fd9\u4e2a\u7ed3\u679c\u5206\u6210\u56db\u4e2a\u90e8\u5206\u3002<\/span><br \/>\n<span style=\"font-size: small;\"> \u7b2c\u4e00\u90e8\u5206\u7684\u4e24\u884c\uff0c\u663e\u793a\u4e24\u4e2a\u6587\u4ef6\u7684\u57fa\u672c\u60c5\u51b5\uff1a\u6587\u4ef6\u540d\u548c\u65f6\u95f4\u4fe1\u606f\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n*** f1\t2012-08-29 16:45:41.000000000 +0800\r\n--- f2\t2012-08-29 16:45:51.000000000 +0800\r\n<\/pre>\n<p><span style=\"font-size: small;\">&#8220;***&#8221;\u8868\u793a\u53d8\u52a8\u524d\u7684\u6587\u4ef6\uff0c&#8221;&#8212;&#8220;\u8868\u793a\u53d8\u52a8\u540e\u7684\u6587\u4ef6\u3002<\/span><br \/>\n<span style=\"font-size: small;\"> \u7b2c\u4e8c\u90e8\u5206\u662f15\u4e2a\u661f\u53f7\uff0c\u5c06\u6587\u4ef6\u7684\u57fa\u672c\u60c5\u51b5\u4e0e\u53d8\u52a8\u5185\u5bb9\u5206\u5272\u5f00\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n***************\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u7b2c\u4e09\u90e8\u5206\u663e\u793a\u53d8\u52a8\u524d\u7684\u6587\u4ef6\uff0c\u5373f1\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n*** 1,7 ****\r\na\r\na\r\na\r\n!a\r\na\r\na\r\na\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u8fd9\u65f6\u4e0d\u4ec5\u663e\u793a\u53d1\u751f\u53d8\u5316\u7684\u7b2c4\u884c\uff0c\u8fd8\u663e\u793a\u7b2c4\u884c\u7684\u524d\u9762\u4e09\u884c\u548c\u540e\u9762\u4e09\u884c\uff0c\u56e0\u6b64\u4e00\u5171\u663e\u793a7\u884c\u3002\u6240\u4ee5\uff0c\u524d\u9762\u7684&#8221;*** 1,7 ****&#8221;\u5c31\u8868\u793a\uff0c\u4ece\u7b2c1\u884c\u5f00\u59cb\u8fde\u7eed7\u884c\u3002<\/span><br \/>\n<span style=\"font-size: small;\"> \u53e6\u5916\uff0c\u6587\u4ef6\u5185\u5bb9\u7684\u6bcf\u4e00\u884c\u6700\u524d\u9762\uff0c\u8fd8\u6709\u4e00\u4e2a\u6807\u8bb0\u4f4d\u3002\u5982\u679c\u4e3a\u7a7a\uff0c\u8868\u793a\u8be5\u884c\u65e0\u53d8\u5316\uff1b\u5982\u679c\u662f\u611f\u53f9\u53f7\uff08!\uff09\uff0c\u8868\u793a\u8be5\u884c\u6709\u6539\u52a8\uff1b\u5982\u679c\u662f\u51cf\u53f7\uff08-\uff09\uff0c\u8868\u793a\u8be5\u884c\u88ab\u5220\u9664\uff1b\u5982\u679c\u662f\u52a0\u53f7\uff08+\uff09\uff0c\u8868\u793a\u8be5\u884c\u4e3a\u65b0\u589e\u3002<\/span><br \/>\n<span style=\"font-size: small;\"> \u7b2c\u56db\u90e8\u5206\u663e\u793a\u53d8\u52a8\u540e\u7684\u6587\u4ef6\uff0c\u5373f2\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n--- 1,7 ----\r\na\r\na\r\na\r\n!b\r\na\r\na\r\na\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u9664\u4e86\u53d8\u52a8\u884c\uff08\u7b2c4\u884c\uff09\u4ee5\u5916\uff0c\u4e5f\u662f\u4e0a\u4e0b\u6587\u5404\u663e\u793a\u4e09\u884c\uff0c\u603b\u5171\u663e\u793a7\u884c\u3002<\/span><\/p>\n<p><span style=\"font-size: small; color: #ff0000;\">\u4e94\u3001\u5408\u5e76\u683c\u5f0f\u7684diff<\/span><\/p>\n<p><span style=\"font-size: small;\">\u5982\u679c\u4e24\u4e2a\u6587\u4ef6\u76f8\u4f3c\u5ea6\u5f88\u9ad8\uff0c\u90a3\u4e48\u4e0a\u4e0b\u6587\u683c\u5f0f\u7684diff\uff0c\u5c06\u663e\u793a\u5927\u91cf\u91cd\u590d\u7684\u5185\u5bb9\uff0c\u5f88\u6d6a\u8d39\u7a7a\u95f4\u30021990\u5e74\uff0cGNU diff\u7387\u5148\u63a8\u51fa\u4e86&#8221;\u5408\u5e76\u683c\u5f0f&#8221;\u7684diff\uff0c\u5c06f1\u548cf2\u7684\u4e0a\u4e0b\u6587\u5408\u5e76\u5728\u4e00\u8d77\u663e\u793a\u3002<\/span><br \/>\n<span style=\"font-size: small;\"> \u5b83\u7684\u4f7f\u7528\u65b9\u6cd5\u662f\u52a0\u5165u\u53c2\u6570\uff08\u4ee3\u8868unified\uff09\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n$ diff -u f1 f2\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u663e\u793a\u7ed3\u679c\u5982\u4e0b\uff1a<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n--- f1\t2012-08-29 16:45:41.000000000 +0800\r\n+++ f2\t2012-08-29 16:45:51.000000000 +0800\r\n@@ -1,7 +1,7 @@\r\na\r\na\r\na\r\n-a\r\n+b\r\na\r\na\r\na\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u5b83\u7684\u7b2c\u4e00\u90e8\u5206\uff0c\u4e5f\u662f\u6587\u4ef6\u7684\u57fa\u672c\u4fe1\u606f\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n--- f1\t2012-08-29 16:45:41.000000000 +0800\r\n+++ f2\t2012-08-29 16:45:51.000000000 +0800\r\n<\/pre>\n<p><span style=\"font-size: small;\">&#8220;&#8212;&#8220;\u8868\u793a\u53d8\u52a8\u524d\u7684\u6587\u4ef6\uff0c&#8221;+++&#8221;\u8868\u793a\u53d8\u52a8\u540e\u7684\u6587\u4ef6\u3002<\/span><br \/>\n<span style=\"font-size: small;\"> \u7b2c\u4e8c\u90e8\u5206\uff0c\u53d8\u52a8\u7684\u4f4d\u7f6e\u7528\u4e24\u4e2a@\u4f5c\u4e3a\u8d77\u9996\u548c\u7ed3\u675f\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n@@ -1,7 +1,7 @@\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u524d\u9762\u7684&#8221;-1,7&#8243;\u5206\u6210\u4e09\u4e2a\u90e8\u5206\uff1a\u51cf\u53f7\u8868\u793a\u7b2c\u4e00\u4e2a\u6587\u4ef6\uff08\u5373f1\uff09\uff0c&#8221;1&#8243;\u8868\u793a\u7b2c1\u884c\uff0c&#8221;7&#8243;\u8868\u793a\u8fde\u7eed7\u884c\u3002\u5408\u5728\u4e00\u8d77\uff0c\u5c31\u8868\u793a\u4e0b\u9762\u662f\u7b2c\u4e00\u4e2a\u6587\u4ef6\u4ece\u7b2c1\u884c\u5f00\u59cb\u7684\u8fde\u7eed7\u884c\u3002\u540c\u6837\u7684\uff0c&#8221;+1,7&#8243;\u8868\u793a\u53d8\u52a8\u540e\uff0c\u6210\u4e3a\u7b2c\u4e8c\u4e2a\u6587\u4ef6\u4ece\u7b2c1\u884c\u5f00\u59cb\u7684\u8fde\u7eed7\u884c\u3002<\/span><br \/>\n<span style=\"font-size: small;\"> \u7b2c\u4e09\u90e8\u5206\u662f\u53d8\u52a8\u7684\u5177\u4f53\u5185\u5bb9\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\na\r\na\r\na\r\n-a\r\n+b\r\na\r\na\r\na\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u9664\u4e86\u6709\u53d8\u52a8\u7684\u90a3\u4e9b\u884c\u4ee5\u5916\uff0c\u4e5f\u662f\u4e0a\u4e0b\u6587\u5404\u663e\u793a3\u884c\u3002\u5b83\u5c06\u4e24\u4e2a\u6587\u4ef6\u7684\u4e0a\u4e0b\u6587\uff0c\u5408\u5e76\u663e\u793a\u5728\u4e00\u8d77\uff0c\u6240\u4ee5\u53eb\u505a&#8221;\u5408\u5e76\u683c\u5f0f&#8221;\u3002\u6bcf\u4e00\u884c\u6700\u524d\u9762\u7684\u6807\u5fd7\u4f4d\uff0c\u7a7a\u8868\u793a\u65e0\u53d8\u52a8\uff0c\u51cf\u53f7\u8868\u793a\u7b2c\u4e00\u4e2a\u6587\u4ef6\u5220\u9664\u7684\u884c\uff0c\u52a0\u53f7\u8868\u793a\u7b2c\u4e8c\u4e2a\u6587\u4ef6\u65b0\u589e\u7684\u884c\u3002<\/span><\/p>\n<p><span style=\"font-size: small; color: #ff0000;\">\u516d\u3001git\u683c\u5f0f\u7684diff<\/span><\/p>\n<p><span style=\"font-size: small;\">\u7248\u672c\u7ba1\u7406\u7cfb\u7edfgit\uff0c\u4f7f\u7528\u7684\u662f\u5408\u5e76\u683c\u5f0fdiff\u7684\u53d8\u4f53\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n$ git diff\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u663e\u793a\u7ed3\u679c\u5982\u4e0b\uff1a<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\ndiff --git a\/f1 b\/f1\r\nindex 6f8a38c..449b072 100644\r\n--- a\/f1\r\n+++ b\/f1\r\n@@ -1,7 +1,7 @@\r\na\r\na\r\na\r\n-a\r\n+b\r\na\r\na\r\na\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u7b2c\u4e00\u884c\u8868\u793a\u7ed3\u679c\u4e3agit\u683c\u5f0f\u7684diff\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\ndiff --git a\/f1 b\/f1\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u8fdb\u884c\u6bd4\u8f83\u7684\u662f\uff0ca\u7248\u672c\u7684f1\uff08\u5373\u53d8\u52a8\u524d\uff09\u548cb\u7248\u672c\u7684f1\uff08\u5373\u53d8\u52a8\u540e\uff09\u3002<\/span><br \/>\n<span style=\"font-size: small;\"> \u7b2c\u4e8c\u884c\u8868\u793a\u4e24\u4e2a\u7248\u672c\u7684git\u54c8\u5e0c\u503c\uff08index\u533a\u57df\u76846f8a38c\u5bf9\u8c61\uff0c\u4e0e\u5de5\u4f5c\u76ee\u5f55\u533a\u57df\u7684449b072\u5bf9\u8c61\u8fdb\u884c\u6bd4\u8f83\uff09\uff0c\u6700\u540e\u7684\u516d\u4f4d\u6570\u5b57\u662f\u5bf9\u8c61\u7684\u6a21\u5f0f\uff08\u666e\u901a\u6587\u4ef6\uff0c644\u6743\u9650\uff09\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\nindex 6f8a38c..449b072 100644\r\n<\/pre>\n<p><span style=\"font-size: small;\">\u7b2c\u4e09\u884c\u8868\u793a\u8fdb\u884c\u6bd4\u8f83\u7684\u4e24\u4e2a\u6587\u4ef6\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n--- a\/f1\r\n+++ b\/f1\r\n<\/pre>\n<p><span style=\"font-size: small;\">&#8220;&#8212;&#8220;\u8868\u793a\u53d8\u52a8\u524d\u7684\u7248\u672c\uff0c&#8221;+++&#8221;\u8868\u793a\u53d8\u52a8\u540e\u7684\u7248\u672c\u3002<\/span><br \/>\n<span style=\"font-size: small;\"> \u540e\u9762\u7684\u884c\u90fd\u4e0e\u5b98\u65b9\u7684\u5408\u5e76\u683c\u5f0fdiff\u76f8\u540c\u3002<\/span><\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\r\n@@ -1,7 +1,7 @@\r\na\r\na\r\na\r\n-a\r\n+b\r\na\r\na\r\na\r\n<\/pre>\n<p><span style=\"font-size: small; color: #ff0000;\">\u8f6c\u8f7d\u81ea\uff1ahttp:\/\/www.ruanyifeng.com\/blog\/2012\/08\/how_to_read_diff.html<\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>diff\u662fUnix\u7cfb\u7edf\u7684\u4e00\u4e2a\u5f88\u91cd\u8981\u7684\u5de5\u5177\u7a0b\u5e8f\u3002 \u5b83\u7528\u6765\u6bd4\u8f83\u4e24\u4e2a\u6587\u672c\u6587\u4ef6\u7684\u5dee\u5f02\uff0c\u662f\u4ee3\u7801\u7248\u672c\u7ba1\u7406\u7684\u57fa\u77f3\u4e4b\u4e00\u3002\u4f60\u5728\u547d [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[],"class_list":["post-2246","post","type-post","status-publish","format-standard","hentry","category-skill"],"_links":{"self":[{"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/posts\/2246","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/comments?post=2246"}],"version-history":[{"count":2,"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/posts\/2246\/revisions"}],"predecessor-version":[{"id":2249,"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/posts\/2246\/revisions\/2249"}],"wp:attachment":[{"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/media?parent=2246"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/categories?post=2246"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kyle.ai\/blog\/wp-json\/wp\/v2\/tags?post=2246"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}