Show More
@@ -998,7 +998,8 b' def filelog(web, req, tmpl):' | |||||
998 | basectx = ctx.p1() |
|
998 | basectx = ctx.p1() | |
999 | path = fctx.path() |
|
999 | path = fctx.path() | |
1000 | return webutil.diffs(web, tmpl, ctx, basectx, [path], diffstyle, |
|
1000 | return webutil.diffs(web, tmpl, ctx, basectx, [path], diffstyle, | |
1001 |
linerange=linerange |
|
1001 | linerange=linerange, | |
|
1002 | lineidprefix='%s-' % ctx.hex()[:12]) | |||
1002 |
|
1003 | |||
1003 | linerange = None |
|
1004 | linerange = None | |
1004 | if lrange is not None: |
|
1005 | if lrange is not None: |
@@ -434,7 +434,8 b' def listfilediffs(tmpl, files, node, max' | |||||
434 | if len(files) > max: |
|
434 | if len(files) > max: | |
435 | yield tmpl('fileellipses') |
|
435 | yield tmpl('fileellipses') | |
436 |
|
436 | |||
437 |
def diffs(web, tmpl, ctx, basectx, files, style, linerange=None |
|
437 | def diffs(web, tmpl, ctx, basectx, files, style, linerange=None, | |
|
438 | lineidprefix=''): | |||
438 |
|
439 | |||
439 | def prettyprintlines(lines, blockno): |
|
440 | def prettyprintlines(lines, blockno): | |
440 | for lineno, l in enumerate(lines, 1): |
|
441 | for lineno, l in enumerate(lines, 1): | |
@@ -450,7 +451,7 b' def diffs(web, tmpl, ctx, basectx, files' | |||||
450 | yield tmpl(ltype, |
|
451 | yield tmpl(ltype, | |
451 | line=l, |
|
452 | line=l, | |
452 | lineno=lineno, |
|
453 | lineno=lineno, | |
453 | lineid="l%s" % difflineno, |
|
454 | lineid=lineidprefix + "l%s" % difflineno, | |
454 | linenumber="% 8s" % difflineno) |
|
455 | linenumber="% 8s" % difflineno) | |
455 |
|
456 | |||
456 | repo = web.repo |
|
457 | repo = web.repo |
@@ -1124,10 +1124,10 b' filelog with patch' | |||||
1124 | </td> |
|
1124 | </td> | |
1125 | </tr> |
|
1125 | </tr> | |
1126 | <tr><td colspan="3"><div class="bottomline inc-lineno"><pre class="sourcelines wrap"> |
|
1126 | <tr><td colspan="3"><div class="bottomline inc-lineno"><pre class="sourcelines wrap"> | |
1127 | <span id="l1.1" class="minusline">--- /dev/null Thu Jan 01 00:00:00 1970 +0000</span><a href="#l1.1"></a> |
|
1127 | <span id="3f41bc784e7e-l1.1" class="minusline">--- /dev/null Thu Jan 01 00:00:00 1970 +0000</span><a href="#3f41bc784e7e-l1.1"></a> | |
1128 | <span id="l1.2" class="plusline">+++ b/a Thu Jan 01 00:00:00 1970 +0000</span><a href="#l1.2"></a> |
|
1128 | <span id="3f41bc784e7e-l1.2" class="plusline">+++ b/a Thu Jan 01 00:00:00 1970 +0000</span><a href="#3f41bc784e7e-l1.2"></a> | |
1129 | <span id="l1.3" class="atline">@@ -0,0 +1,1 @@</span><a href="#l1.3"></a> |
|
1129 | <span id="3f41bc784e7e-l1.3" class="atline">@@ -0,0 +1,1 @@</span><a href="#3f41bc784e7e-l1.3"></a> | |
1130 | <span id="l1.4" class="plusline">+b</span><a href="#l1.4"></a></pre></div></td></tr> |
|
1130 | <span id="3f41bc784e7e-l1.4" class="plusline">+b</span><a href="#3f41bc784e7e-l1.4"></a></pre></div></td></tr> | |
1131 | <tr> |
|
1131 | <tr> | |
1132 | <td class="age">Thu, 01 Jan 1970 00:00:00 +0000</td> |
|
1132 | <td class="age">Thu, 01 Jan 1970 00:00:00 +0000</td> | |
1133 | <td class="author">test</td> |
|
1133 | <td class="author">test</td> | |
@@ -1137,10 +1137,10 b' filelog with patch' | |||||
1137 | </td> |
|
1137 | </td> | |
1138 | </tr> |
|
1138 | </tr> | |
1139 | <tr><td colspan="3"><div class="bottomline inc-lineno"><pre class="sourcelines wrap"> |
|
1139 | <tr><td colspan="3"><div class="bottomline inc-lineno"><pre class="sourcelines wrap"> | |
1140 | <span id="l1.1" class="minusline">--- /dev/null Thu Jan 01 00:00:00 1970 +0000</span><a href="#l1.1"></a> |
|
1140 | <span id="5ed941583260-l1.1" class="minusline">--- /dev/null Thu Jan 01 00:00:00 1970 +0000</span><a href="#5ed941583260-l1.1"></a> | |
1141 | <span id="l1.2" class="plusline">+++ b/a Thu Jan 01 00:00:00 1970 +0000</span><a href="#l1.2"></a> |
|
1141 | <span id="5ed941583260-l1.2" class="plusline">+++ b/a Thu Jan 01 00:00:00 1970 +0000</span><a href="#5ed941583260-l1.2"></a> | |
1142 | <span id="l1.3" class="atline">@@ -0,0 +1,1 @@</span><a href="#l1.3"></a> |
|
1142 | <span id="5ed941583260-l1.3" class="atline">@@ -0,0 +1,1 @@</span><a href="#5ed941583260-l1.3"></a> | |
1143 | <span id="l1.4" class="plusline">+a</span><a href="#l1.4"></a></pre></div></td></tr> |
|
1143 | <span id="5ed941583260-l1.4" class="plusline">+a</span><a href="#5ed941583260-l1.4"></a></pre></div></td></tr> | |
1144 |
|
1144 | |||
1145 | </tbody> |
|
1145 | </tbody> | |
1146 | </table> |
|
1146 | </table> | |
@@ -1404,16 +1404,16 b" filelog with 'linerange' and 'patch'" | |||||
1404 | </td> |
|
1404 | </td> | |
1405 | </tr> |
|
1405 | </tr> | |
1406 | <tr><td colspan="3"><div class="bottomline inc-lineno"><pre class="sourcelines wrap"> |
|
1406 | <tr><td colspan="3"><div class="bottomline inc-lineno"><pre class="sourcelines wrap"> | |
1407 | <span id="l1.1" class="minusline">--- a/c Thu Jan 01 00:00:00 1970 +0000</span><a href="#l1.1"></a> |
|
1407 | <span id="fb9bc322513a-l1.1" class="minusline">--- a/c Thu Jan 01 00:00:00 1970 +0000</span><a href="#fb9bc322513a-l1.1"></a> | |
1408 | <span id="l1.2" class="plusline">+++ b/c Thu Jan 01 00:00:00 1970 +0000</span><a href="#l1.2"></a> |
|
1408 | <span id="fb9bc322513a-l1.2" class="plusline">+++ b/c Thu Jan 01 00:00:00 1970 +0000</span><a href="#fb9bc322513a-l1.2"></a> | |
1409 | <span id="l1.3" class="atline">@@ -1,6 +1,6 @@</span><a href="#l1.3"></a> |
|
1409 | <span id="fb9bc322513a-l1.3" class="atline">@@ -1,6 +1,6 @@</span><a href="#fb9bc322513a-l1.3"></a> | |
1410 | <span id="l1.4"> 0</span><a href="#l1.4"></a> |
|
1410 | <span id="fb9bc322513a-l1.4"> 0</span><a href="#fb9bc322513a-l1.4"></a> | |
1411 | <span id="l1.5"> 0</span><a href="#l1.5"></a> |
|
1411 | <span id="fb9bc322513a-l1.5"> 0</span><a href="#fb9bc322513a-l1.5"></a> | |
1412 | <span id="l1.6" class="minusline">-b</span><a href="#l1.6"></a> |
|
1412 | <span id="fb9bc322513a-l1.6" class="minusline">-b</span><a href="#fb9bc322513a-l1.6"></a> | |
1413 | <span id="l1.7" class="plusline">+b-</span><a href="#l1.7"></a> |
|
1413 | <span id="fb9bc322513a-l1.7" class="plusline">+b-</span><a href="#fb9bc322513a-l1.7"></a> | |
1414 | <span id="l1.8"> c++</span><a href="#l1.8"></a> |
|
1414 | <span id="fb9bc322513a-l1.8"> c++</span><a href="#fb9bc322513a-l1.8"></a> | |
1415 | <span id="l1.9"> </span><a href="#l1.9"></a> |
|
1415 | <span id="fb9bc322513a-l1.9"> </span><a href="#fb9bc322513a-l1.9"></a> | |
1416 | <span id="l1.10"> a</span><a href="#l1.10"></a></pre></div></td></tr> |
|
1416 | <span id="fb9bc322513a-l1.10"> a</span><a href="#fb9bc322513a-l1.10"></a></pre></div></td></tr> | |
1417 | <tr> |
|
1417 | <tr> | |
1418 | <td class="age">Thu, 01 Jan 1970 00:00:00 +0000</td> |
|
1418 | <td class="age">Thu, 01 Jan 1970 00:00:00 +0000</td> | |
1419 | <td class="author">test</td> |
|
1419 | <td class="author">test</td> | |
@@ -1423,17 +1423,17 b" filelog with 'linerange' and 'patch'" | |||||
1423 | </td> |
|
1423 | </td> | |
1424 | </tr> |
|
1424 | </tr> | |
1425 | <tr><td colspan="3"><div class="bottomline inc-lineno"><pre class="sourcelines wrap"> |
|
1425 | <tr><td colspan="3"><div class="bottomline inc-lineno"><pre class="sourcelines wrap"> | |
1426 | <span id="l1.1" class="minusline">--- a/c Thu Jan 01 00:00:00 1970 +0000</span><a href="#l1.1"></a> |
|
1426 | <span id="e95928d60479-l1.1" class="minusline">--- a/c Thu Jan 01 00:00:00 1970 +0000</span><a href="#e95928d60479-l1.1"></a> | |
1427 | <span id="l1.2" class="plusline">+++ b/c Thu Jan 01 00:00:00 1970 +0000</span><a href="#l1.2"></a> |
|
1427 | <span id="e95928d60479-l1.2" class="plusline">+++ b/c Thu Jan 01 00:00:00 1970 +0000</span><a href="#e95928d60479-l1.2"></a> | |
1428 | <span id="l1.3" class="atline">@@ -1,7 +1,7 @@</span><a href="#l1.3"></a> |
|
1428 | <span id="e95928d60479-l1.3" class="atline">@@ -1,7 +1,7 @@</span><a href="#e95928d60479-l1.3"></a> | |
1429 | <span id="l1.4"> 0</span><a href="#l1.4"></a> |
|
1429 | <span id="e95928d60479-l1.4"> 0</span><a href="#e95928d60479-l1.4"></a> | |
1430 | <span id="l1.5"> 0</span><a href="#l1.5"></a> |
|
1430 | <span id="e95928d60479-l1.5"> 0</span><a href="#e95928d60479-l1.5"></a> | |
1431 | <span id="l1.6"> b</span><a href="#l1.6"></a> |
|
1431 | <span id="e95928d60479-l1.6"> b</span><a href="#e95928d60479-l1.6"></a> | |
1432 | <span id="l1.7" class="minusline">-c+</span><a href="#l1.7"></a> |
|
1432 | <span id="e95928d60479-l1.7" class="minusline">-c+</span><a href="#e95928d60479-l1.7"></a> | |
1433 | <span id="l1.8" class="plusline">+c++</span><a href="#l1.8"></a> |
|
1433 | <span id="e95928d60479-l1.8" class="plusline">+c++</span><a href="#e95928d60479-l1.8"></a> | |
1434 | <span id="l1.9"> </span><a href="#l1.9"></a> |
|
1434 | <span id="e95928d60479-l1.9"> </span><a href="#e95928d60479-l1.9"></a> | |
1435 | <span id="l1.10"> a</span><a href="#l1.10"></a> |
|
1435 | <span id="e95928d60479-l1.10"> a</span><a href="#e95928d60479-l1.10"></a> | |
1436 | <span id="l1.11"> a</span><a href="#l1.11"></a></pre></div></td></tr> |
|
1436 | <span id="e95928d60479-l1.11"> a</span><a href="#e95928d60479-l1.11"></a></pre></div></td></tr> | |
1437 | <tr> |
|
1437 | <tr> | |
1438 | <td class="age">Thu, 01 Jan 1970 00:00:00 +0000</td> |
|
1438 | <td class="age">Thu, 01 Jan 1970 00:00:00 +0000</td> | |
1439 | <td class="author">test</td> |
|
1439 | <td class="author">test</td> | |
@@ -1443,21 +1443,21 b" filelog with 'linerange' and 'patch'" | |||||
1443 | </td> |
|
1443 | </td> | |
1444 | </tr> |
|
1444 | </tr> | |
1445 | <tr><td colspan="3"><div class="bottomline inc-lineno"><pre class="sourcelines wrap"> |
|
1445 | <tr><td colspan="3"><div class="bottomline inc-lineno"><pre class="sourcelines wrap"> | |
1446 | <span id="l1.1" class="minusline">--- a/c Thu Jan 01 00:00:00 1970 +0000</span><a href="#l1.1"></a> |
|
1446 | <span id="5c6574614c37-l1.1" class="minusline">--- a/c Thu Jan 01 00:00:00 1970 +0000</span><a href="#5c6574614c37-l1.1"></a> | |
1447 | <span id="l1.2" class="plusline">+++ b/c Thu Jan 01 00:00:00 1970 +0000</span><a href="#l1.2"></a> |
|
1447 | <span id="5c6574614c37-l1.2" class="plusline">+++ b/c Thu Jan 01 00:00:00 1970 +0000</span><a href="#5c6574614c37-l1.2"></a> | |
1448 | <span id="l1.3" class="atline">@@ -1,2 +1,11 @@</span><a href="#l1.3"></a> |
|
1448 | <span id="5c6574614c37-l1.3" class="atline">@@ -1,2 +1,11 @@</span><a href="#5c6574614c37-l1.3"></a> | |
1449 | <span id="l1.4" class="plusline">+0</span><a href="#l1.4"></a> |
|
1449 | <span id="5c6574614c37-l1.4" class="plusline">+0</span><a href="#5c6574614c37-l1.4"></a> | |
1450 | <span id="l1.5" class="plusline">+0</span><a href="#l1.5"></a> |
|
1450 | <span id="5c6574614c37-l1.5" class="plusline">+0</span><a href="#5c6574614c37-l1.5"></a> | |
1451 | <span id="l1.6"> b</span><a href="#l1.6"></a> |
|
1451 | <span id="5c6574614c37-l1.6"> b</span><a href="#5c6574614c37-l1.6"></a> | |
1452 | <span id="l1.7" class="minusline">-c</span><a href="#l1.7"></a> |
|
1452 | <span id="5c6574614c37-l1.7" class="minusline">-c</span><a href="#5c6574614c37-l1.7"></a> | |
1453 | <span id="l1.8" class="plusline">+c+</span><a href="#l1.8"></a> |
|
1453 | <span id="5c6574614c37-l1.8" class="plusline">+c+</span><a href="#5c6574614c37-l1.8"></a> | |
1454 | <span id="l1.9" class="plusline">+</span><a href="#l1.9"></a> |
|
1454 | <span id="5c6574614c37-l1.9" class="plusline">+</span><a href="#5c6574614c37-l1.9"></a> | |
1455 | <span id="l1.10" class="plusline">+a</span><a href="#l1.10"></a> |
|
1455 | <span id="5c6574614c37-l1.10" class="plusline">+a</span><a href="#5c6574614c37-l1.10"></a> | |
1456 | <span id="l1.11" class="plusline">+a</span><a href="#l1.11"></a> |
|
1456 | <span id="5c6574614c37-l1.11" class="plusline">+a</span><a href="#5c6574614c37-l1.11"></a> | |
1457 | <span id="l1.12" class="plusline">+</span><a href="#l1.12"></a> |
|
1457 | <span id="5c6574614c37-l1.12" class="plusline">+</span><a href="#5c6574614c37-l1.12"></a> | |
1458 | <span id="l1.13" class="plusline">+d</span><a href="#l1.13"></a> |
|
1458 | <span id="5c6574614c37-l1.13" class="plusline">+d</span><a href="#5c6574614c37-l1.13"></a> | |
1459 | <span id="l1.14" class="plusline">+e</span><a href="#l1.14"></a> |
|
1459 | <span id="5c6574614c37-l1.14" class="plusline">+e</span><a href="#5c6574614c37-l1.14"></a> | |
1460 | <span id="l1.15" class="plusline">+f</span><a href="#l1.15"></a></pre></div></td></tr> |
|
1460 | <span id="5c6574614c37-l1.15" class="plusline">+f</span><a href="#5c6574614c37-l1.15"></a></pre></div></td></tr> | |
1461 | <tr> |
|
1461 | <tr> | |
1462 | <td class="age">Thu, 01 Jan 1970 00:00:00 +0000</td> |
|
1462 | <td class="age">Thu, 01 Jan 1970 00:00:00 +0000</td> | |
1463 | <td class="author">test</td> |
|
1463 | <td class="author">test</td> | |
@@ -1467,11 +1467,11 b" filelog with 'linerange' and 'patch'" | |||||
1467 | </td> |
|
1467 | </td> | |
1468 | </tr> |
|
1468 | </tr> | |
1469 | <tr><td colspan="3"><div class="bottomline inc-lineno"><pre class="sourcelines wrap"> |
|
1469 | <tr><td colspan="3"><div class="bottomline inc-lineno"><pre class="sourcelines wrap"> | |
1470 | <span id="l1.1" class="minusline">--- a/c Thu Jan 01 00:00:00 1970 +0000</span><a href="#l1.1"></a> |
|
1470 | <span id="46c1a66bd8fc-l1.1" class="minusline">--- a/c Thu Jan 01 00:00:00 1970 +0000</span><a href="#46c1a66bd8fc-l1.1"></a> | |
1471 | <span id="l1.2" class="plusline">+++ b/c Thu Jan 01 00:00:00 1970 +0000</span><a href="#l1.2"></a> |
|
1471 | <span id="46c1a66bd8fc-l1.2" class="plusline">+++ b/c Thu Jan 01 00:00:00 1970 +0000</span><a href="#46c1a66bd8fc-l1.2"></a> | |
1472 | <span id="l1.3" class="atline">@@ -1,1 +1,2 @@</span><a href="#l1.3"></a> |
|
1472 | <span id="46c1a66bd8fc-l1.3" class="atline">@@ -1,1 +1,2 @@</span><a href="#46c1a66bd8fc-l1.3"></a> | |
1473 | <span id="l1.4"> b</span><a href="#l1.4"></a> |
|
1473 | <span id="46c1a66bd8fc-l1.4"> b</span><a href="#46c1a66bd8fc-l1.4"></a> | |
1474 | <span id="l1.5" class="plusline">+c</span><a href="#l1.5"></a></pre></div></td></tr> |
|
1474 | <span id="46c1a66bd8fc-l1.5" class="plusline">+c</span><a href="#46c1a66bd8fc-l1.5"></a></pre></div></td></tr> | |
1475 | <tr> |
|
1475 | <tr> | |
1476 | <td class="age">Thu, 01 Jan 1970 00:00:00 +0000</td> |
|
1476 | <td class="age">Thu, 01 Jan 1970 00:00:00 +0000</td> | |
1477 | <td class="author">test</td> |
|
1477 | <td class="author">test</td> | |
@@ -1481,8 +1481,8 b" filelog with 'linerange' and 'patch'" | |||||
1481 | </td> |
|
1481 | </td> | |
1482 | </tr> |
|
1482 | </tr> | |
1483 | <tr><td colspan="3"><div class="bottomline inc-lineno"><pre class="sourcelines wrap"> |
|
1483 | <tr><td colspan="3"><div class="bottomline inc-lineno"><pre class="sourcelines wrap"> | |
1484 | <span id="l1.1" class="minusline">--- /dev/null Thu Jan 01 00:00:00 1970 +0000</span><a href="#l1.1"></a> |
|
1484 | <span id="6563da9dcf87-l1.1" class="minusline">--- /dev/null Thu Jan 01 00:00:00 1970 +0000</span><a href="#6563da9dcf87-l1.1"></a> | |
1485 | <span id="l1.2" class="plusline">+++ b/b Thu Jan 01 00:00:00 1970 +0000</span><a href="#l1.2"></a></pre></div></td></tr> |
|
1485 | <span id="6563da9dcf87-l1.2" class="plusline">+++ b/b Thu Jan 01 00:00:00 1970 +0000</span><a href="#6563da9dcf87-l1.2"></a></pre></div></td></tr> | |
1486 |
|
1486 | |||
1487 | </tbody> |
|
1487 | </tbody> | |
1488 | </table> |
|
1488 | </table> |
General Comments 0
You need to be logged in to leave comments.
Login now