##// END OF EJS Templates
Fix gitweb to not say shortlog instead of graph.
Augie Fackler -
r6727:f4b6dec9 default
parent child Browse files
Show More
@@ -1,123 +1,123 b''
1 #header#
1 #header#
2 <title>#repo|escape#: Shortlog</title>
2 <title>#repo|escape#: Graph</title>
3 <link rel="alternate" type="application/atom+xml"
3 <link rel="alternate" type="application/atom+xml"
4 href="{url}atom-log" title="Atom feed for #repo|escape#"/>
4 href="{url}atom-log" title="Atom feed for #repo|escape#"/>
5 <link rel="alternate" type="application/rss+xml"
5 <link rel="alternate" type="application/rss+xml"
6 href="{url}rss-log" title="RSS feed for #repo|escape#"/>
6 href="{url}rss-log" title="RSS feed for #repo|escape#"/>
7 </head>
7 </head>
8 <body>
8 <body>
9
9
10 <div class="page_header">
10 <div class="page_header">
11 <a href="http://www.selenic.com/mercurial/" title="Mercurial" style="float: right;">Mercurial</a><a href="{url}summary{sessionvars%urlparameter}">#repo|escape#</a> / shortlog
11 <a href="http://www.selenic.com/mercurial/" title="Mercurial" style="float: right;">Mercurial</a><a href="{url}summary{sessionvars%urlparameter}">#repo|escape#</a> / graph
12 </div>
12 </div>
13
13
14 <form action="{url}log">
14 <form action="{url}log">
15 {sessionvars%hiddenformentry}
15 {sessionvars%hiddenformentry}
16 <div class="search">
16 <div class="search">
17 <input type="text" name="rev" />
17 <input type="text" name="rev" />
18 </div>
18 </div>
19 </form>
19 </form>
20 <div class="page_nav">
20 <div class="page_nav">
21 <a href="{url}summary{sessionvars%urlparameter}">summary</a> |
21 <a href="{url}summary{sessionvars%urlparameter}">summary</a> |
22 <a href="{url}shortlog{sessionvars%urlparameter}">shortlog</a> |
22 <a href="{url}shortlog{sessionvars%urlparameter}">shortlog</a> |
23 <a href="{url}log/#rev#{sessionvars%urlparameter}">changelog</a> |
23 <a href="{url}log/#rev#{sessionvars%urlparameter}">changelog</a> |
24 graph |
24 graph |
25 <a href="{url}tags{sessionvars%urlparameter}">tags</a> |
25 <a href="{url}tags{sessionvars%urlparameter}">tags</a> |
26 <a href="{url}file/#node|short#{sessionvars%urlparameter}">files</a>
26 <a href="{url}file/#node|short#{sessionvars%urlparameter}">files</a>
27 <br/>
27 <br/>
28 <a href="{url}graph/{uprev}{sessionvars%urlparameter}?revcount={revcountless}">less</a>
28 <a href="{url}graph/{uprev}{sessionvars%urlparameter}?revcount={revcountless}">less</a>
29 <a href="{url}graph/{uprev}{sessionvars%urlparameter}?revcount={revcountmore}">more</a>
29 <a href="{url}graph/{uprev}{sessionvars%urlparameter}?revcount={revcountmore}">more</a>
30 | #changenav%navgraphentry#<br/>
30 | #changenav%navgraphentry#<br/>
31 </div>
31 </div>
32
32
33 <div class="title">&nbsp;</div>
33 <div class="title">&nbsp;</div>
34
34
35 <div id="noscript">The revision graph only works with JavaScript-enabled browsers.</div>
35 <div id="noscript">The revision graph only works with JavaScript-enabled browsers.</div>
36
36
37 <div id="wrapper">
37 <div id="wrapper">
38 <ul id="nodebgs"></ul>
38 <ul id="nodebgs"></ul>
39 <canvas id="graph" width="224" height="#canvasheight#"></canvas>
39 <canvas id="graph" width="224" height="#canvasheight#"></canvas>
40 <ul id="graphnodes"></ul>
40 <ul id="graphnodes"></ul>
41 </div>
41 </div>
42
42
43 <script type="text/javascript" src="#staticurl#graph.js"></script>
43 <script type="text/javascript" src="#staticurl#graph.js"></script>
44 <script>
44 <script>
45
45
46 document.getElementById('noscript').style.visibility = 'hidden';
46 document.getElementById('noscript').style.visibility = 'hidden';
47
47
48 data = {jsdata|json};
48 data = {jsdata|json};
49 graph = new Graph();
49 graph = new Graph();
50 graph.scale({bg_height});
50 graph.scale({bg_height});
51
51
52 graph.edge = function(x0, y0, x1, y1, color) {
52 graph.edge = function(x0, y0, x1, y1, color) {
53
53
54 this.setColor(color, 0.0, 0.65);
54 this.setColor(color, 0.0, 0.65);
55 this.ctx.beginPath();
55 this.ctx.beginPath();
56 this.ctx.moveTo(x0, y0);
56 this.ctx.moveTo(x0, y0);
57 this.ctx.lineTo(x1, y1);
57 this.ctx.lineTo(x1, y1);
58 this.ctx.stroke();
58 this.ctx.stroke();
59
59
60 }
60 }
61
61
62 var nodes = document.getElementById('graphnodes');
62 var nodes = document.getElementById('graphnodes');
63 var nodebgs = document.getElementById('nodebgs');
63 var nodebgs = document.getElementById('nodebgs');
64
64
65 var revlink = '<li style="_STYLE"><span class="desc">';
65 var revlink = '<li style="_STYLE"><span class="desc">';
66 revlink += '<a class="list" href="{url}rev/_NODEID{sessionvars%urlparameter}" title="_NODEID"><b>_DESC</b></a>';
66 revlink += '<a class="list" href="{url}rev/_NODEID{sessionvars%urlparameter}" title="_NODEID"><b>_DESC</b></a>';
67 revlink += '</span> _TAGS';
67 revlink += '</span> _TAGS';
68 revlink += '<span class="info">_DATE ago, by _USER</span></li>';
68 revlink += '<span class="info">_DATE ago, by _USER</span></li>';
69
69
70 graph.vertex = function(x, y, color, parity, cur) {
70 graph.vertex = function(x, y, color, parity, cur) {
71
71
72 this.ctx.beginPath();
72 this.ctx.beginPath();
73 color = this.setColor(color, 0.25, 0.75);
73 color = this.setColor(color, 0.25, 0.75);
74 this.ctx.arc(x, y, radius, 0, Math.PI * 2, true);
74 this.ctx.arc(x, y, radius, 0, Math.PI * 2, true);
75 this.ctx.fill();
75 this.ctx.fill();
76
76
77 var bg = '<li class="bg parity' + parity + '"></li>';
77 var bg = '<li class="bg parity' + parity + '"></li>';
78 nodebgs.innerHTML += bg;
78 nodebgs.innerHTML += bg;
79
79
80 var left = (this.columns + 1) * this.bg_height;
80 var left = (this.columns + 1) * this.bg_height;
81 var nstyle = 'padding-left: ' + left + 'px;';
81 var nstyle = 'padding-left: ' + left + 'px;';
82 var item = revlink.replace(/_STYLE/, nstyle);
82 var item = revlink.replace(/_STYLE/, nstyle);
83 item = item.replace(/_PARITY/, 'parity' + parity);
83 item = item.replace(/_PARITY/, 'parity' + parity);
84 item = item.replace(/_NODEID/, cur[0]);
84 item = item.replace(/_NODEID/, cur[0]);
85 item = item.replace(/_NODEID/, cur[0]);
85 item = item.replace(/_NODEID/, cur[0]);
86 item = item.replace(/_DESC/, cur[3]);
86 item = item.replace(/_DESC/, cur[3]);
87 item = item.replace(/_USER/, cur[4]);
87 item = item.replace(/_USER/, cur[4]);
88 item = item.replace(/_DATE/, cur[5]);
88 item = item.replace(/_DATE/, cur[5]);
89
89
90 var tagspan = '';
90 var tagspan = '';
91 if (cur[7].length || (cur[6][0] != 'default' || cur[6][1])) {
91 if (cur[7].length || (cur[6][0] != 'default' || cur[6][1])) {
92 tagspan = '<span class="logtags">';
92 tagspan = '<span class="logtags">';
93 if (cur[6][1]) {
93 if (cur[6][1]) {
94 tagspan += '<span class="branchtag" title="' + cur[6][0] + '">';
94 tagspan += '<span class="branchtag" title="' + cur[6][0] + '">';
95 tagspan += cur[6][0] + '</span> ';
95 tagspan += cur[6][0] + '</span> ';
96 } else if (!cur[6][1] && cur[6][0] != 'default') {
96 } else if (!cur[6][1] && cur[6][0] != 'default') {
97 tagspan += '<span class="inbranchtag" title="' + cur[6][0] + '">';
97 tagspan += '<span class="inbranchtag" title="' + cur[6][0] + '">';
98 tagspan += cur[6][0] + '</span> ';
98 tagspan += cur[6][0] + '</span> ';
99 }
99 }
100 if (cur[7].length) {
100 if (cur[7].length) {
101 for (var t in cur[7]) {
101 for (var t in cur[7]) {
102 var tag = cur[7][t];
102 var tag = cur[7][t];
103 tagspan += '<span class="tagtag">' + tag + '</span> ';
103 tagspan += '<span class="tagtag">' + tag + '</span> ';
104 }
104 }
105 }
105 }
106 tagspan += '</span>';
106 tagspan += '</span>';
107 }
107 }
108
108
109 item = item.replace(/_TAGS/, tagspan);
109 item = item.replace(/_TAGS/, tagspan);
110 nodes.innerHTML += item;
110 nodes.innerHTML += item;
111
111
112 }
112 }
113
113
114 graph.render(data);
114 graph.render(data);
115 </script>
115 </script>
116
116
117 <div class="page_nav">
117 <div class="page_nav">
118 <a href="{url}graph/{uprev}{sessionvars%urlparameter}?revcount={revcountless}">less</a>
118 <a href="{url}graph/{uprev}{sessionvars%urlparameter}?revcount={revcountless}">less</a>
119 <a href="{url}graph/{uprev}{sessionvars%urlparameter}?revcount={revcountmore}">more</a>
119 <a href="{url}graph/{uprev}{sessionvars%urlparameter}?revcount={revcountmore}">more</a>
120 | {changenav%navgraphentry}
120 | {changenav%navgraphentry}
121 </div>
121 </div>
122
122
123 #footer#
123 #footer#
General Comments 0
You need to be logged in to leave comments. Login now