]> git.deb.at Git - deb/packages.git/blob - templates/html/show.tmpl
0ef593e7bafd9bc51598bbe2d90ee15d9b4bb78f
[deb/packages.git] / templates / html / show.tmpl
1 [% PROCESS 'config/archive_layout.tmpl' %]
2 [% PROCESS 'config/mirrors.tmpl' %]
3 [%- nav_arr = [ { prefix=>'Distribution:', title=>'Overview over this suite', url=>make_url('/','','source',''), name=>suite }, ];
4     nav_arr.push( { title => 'Source packages', url=>make_url('/'), name=>'Source' } ) IF is_source;
5     nav_arr.push( { prefix=>'Section:', title=>'All packages in this section', url=>make_url("$subsection/"), name=>subsection } );
6     nav_arr.push( { prefix=>'Package:', name=>pkg } ); -%]
7 [% desclang = 'en';
8    SET desclang = lang IF desc.$lang.long %]
9 [%- PROCESS 'html/head.tmpl'
10    title_tag = ( is_source ? "Details of source package $pkg in $suite"
11                            : "Details of package $pkg in $suite" )
12    description = desc.$desclang.short
13    keywords = "$suite, $archive, $section, $subsection, $version"
14    print_search_field = 'packages'
15    search_field_values = { 
16                           searchon => is_source ? 'sourcenames' : 'names',
17                          }
18   navigation = nav_arr
19 -%]
20 <!-- show.tmpl -->
21 [% PROCESS 'html/menu.inc' %]
22 [% FOREACH s IN suites %]
23    [% '<div id="pothers">' IF loop.first %]
24    [%- IF s == suite -%]
25      [% PROCESS menuitem name=s url='' %]
26    [%- ELSE -%]
27      [% PROCESS menuitem name=s url=make_url(pkg,'','suite',s) %]
28    [%- END -%]
29    [%- '</div>' IF loop.last -%]
30 [% END %]
31
32 [% IF src %]
33 <div id="psource">
34 [% PROCESS menuitem prefix='Source:' title='Source package building this package' url=make_url(src.pkg,'','source','source') name=src.pkg %]
35 </div>
36 [% END %]
37
38 [%- PROCESS 'html/messages.tmpl' -%]
39
40 [% IF is_virtual %]
41 <h1>Virtual Package: [% pkg %]
42 [% ELSIF is_source %]
43 <h1>Source Package: [% pkg %] ([% version %])
44 [% ELSE %]
45 <h1>Package: [% pkg %] ([% versions.short %])
46 [% END %]
47 [%- PROCESS marker text=archive IF archive && archive != main_archive %]
48 [%- PROCESS marker text=subsection IF subsection == 'non-US' and archive != 'non-US' %]
49 [%- PROCESS marker text=section IF section && section != main_section %]
50 [%- PROCESS marker text='essential' IF page.get_newest('essential') == 'yes' %]</h1>
51
52 [% UNLESS is_virtual %]
53 <div id="pmoreinfo">
54 <h2>Links for [% pkg %]</h2>
55 <h3>Debian Resources:</h3>
56 <ul>
57 <li><a href="[% (is_source ? src_bugs_url : bugs_url) _ pkg | uri %]">Bug Reports</a></li>
58
59 [% IF src.pkg -%]
60 <li><a href="[% pts_url _ src.pkg | uri %]">Developer Information (PTS)</a></li>
61 [% ELSIF is_source %]
62 <li><a href="[% pts_url _ pkg | uri %]">Developer Information (PTS)</a></li>
63 [%- END %]
64
65 [% IF files %]
66 <li><a href="[% changelogs_url _ files.changelog.path %]">Debian Changelog</a></li>
67 <li><a href="[% changelogs_url _ files.copyright.path %]">Copyright File</a></li>
68 [% END %]
69 </ul>
70
71 [% vcs_link = page.get_newest("vcs-browser") %]
72 [% #FIXME: should this only be used for the PTS?
73    known_vcs = [ [ 'cvs', 'CVS', 'cvs' ],
74                 [ 'svn', 'Subversion', 'subversion' ],
75                 [ 'bzr', 'bzr', 'bzr' ],
76                 [ 'darcs', 'Darcs', 'darcs' ],
77                 [ 'arch', 'arch', 'tla' ],
78                 [ 'git', 'Git', 'git-core' ],
79                 [ 'hg', 'Hg', 'mercurial' ], ];
80    FOREACH vcs IN known_vcs;
81         vcs_id = vcs.0; vcs_name = vcs.1; vcs_pkg = vcs.2;
82         vcs_info = page.get_newest("vcs-$vcs_id");
83         SET vcs_info = page.get_newest("x-vcs-$vcs_id") UNLESS vcs_info;
84         IF vcs_info; %]
85 <p>Debian Package Repository (<acronym title="Version Control System">VCS</acronym>:
86 <a href="[% make_url(vcs_pkg,'','source','') %]">[% vcs_name %]</a>):<br> <a href="[% vcs_info %]" class="pvcslink">[% vcs_info %]</a></p>
87 [% IF vcs_link %]
88 <p>Debian Package Repository (Browsable):<br> <a href="[% vcs_link %]" class="pvcslink">[% vcs_link %]</a></p>
89 [% END; END; END %]
90
91 [% IF src %]
92   <p>Download Source Package <a href="[% src.url %]">[% src.pkg %]</a>:
93   [% FOREACH src.downloads %]
94     [% '<ul>' IF loop.first %]
95     <li><a href="[% server _ path %]">[[% name %]]</a></li>
96     [% '</ul>' IF loop.last %]
97   [% END %]
98   [% IF src.downloads.size == 0 %]
99   Not found
100   [% END %]
101 [% END %]
102
103 [% IF maintainers.size == 1 -%]
104   <h3>Maintainer:</h3>
105   [%- FOREACH maintainers -%]
106         <a href="mailto:[% mail %]">[% name | html %]</a>
107         (<a href="[% ddpo_url _ mail %]" title="An overview over the maintainer's packages and uploads">QA Page</a>)
108   [%- END -%]
109 [%- ELSE -%]
110   <h3>Maintainers:</h3>
111   [%- FOREACH maintainers -%]
112     [%- '<ul>' IF loop.first -%]
113         <li><a href="mailto:[% mail %]">[% name | html %]</a>
114         (<a href="[% ddpo_url _ mail %]" title="An overview over the maintainer's packages and uploads">QA Page</a>)
115         </li>
116     [%- '</ul>' IF loop.last -%]
117   [%- END -%]
118 [%- END %]
119
120 [% url = page.get_newest('url');
121    IF url %]
122 <h3>External Resources:</h3>
123 <p>Homepage: <a href="[% url | uri %]">[% url | html %]</a></p>
124 [% END %]
125
126 </div> <!-- end pmoreinfo -->
127 [% END %]
128
129 [% IF suite == "experimental" || subsection == "debian-installer" %]
130 <div class="pconstantnag">
131 [% IF suite == "experimental" %]
132 [% changelog_link = 'changelog';
133    changelog_link = "<a href='$changelogs_url$files.changelog.path'>changelog</a>" %] 
134 <h2>Experimental package</h2>
135 <p>Warning: This package is from the <strong>experimental</strong> distribution.
136 That means it is likely unstable or buggy, and it may even cause data loss.
137 Please be sure to consult the [% changelog_link %] and other possible documentation before
138 using it.</p>
139 [% END %]
140 [% IF subsection == "debian-installer" %]
141 <h2>debian-installer udeb package</h2>
142 <p>Warning: This package is intended for the use in building
143 <a href="http://www.debian.org/devel/debian-installer">debian-installer</a> images only.
144 Do not install it on a normal Debian system.</p>
145 [% END %]
146 </div>
147 [% END %]
148
149 <div id="ptablist">
150 </div>
151
152 [% IF desc %]
153 <div id="pdesctab">
154 <div id="pdesc">
155 [% UNLESS is_virtual %]
156         [% IF desc.$desclang.short %]
157         <h2>[% desc.$desclang.short %]</h2>
158         <p>[% desc.$desclang.long %]
159         [% END %]
160 [% ELSE %]
161         <p>This is a <em>virtual package</em>. See the <a href="[% policy_url %]">Debian policy</a> for a <a href="[% policy_url %]ch-binary.html#s-virtual_pkg">definition of virtual packages</a>.</p>
162 [% END %]
163 </div> <!-- end pdesc -->
164
165 [% FOREACH tag IN tags %]
166   [% IF loop.first -%]
167     <div id="ptags"><p>
168     <a href="[% tags_url %]edit.html?pkg=[% pkg | uri %]">Tags</a>:
169   [%- END %]
170   [% facet = tag.0;
171      facet_name = debtags_voc.$facet;
172      tag_id = "$tag.0::$tag.1";
173      tag_name = debtags_voc.$tag_id;
174    %]
175   [% facet_name _ ': ' UNLESS old_facet && facet == old_facet %]
176   [% IF tag_name %]
177    <a href="/about/debtags#[% string2id(tag_id) %]">[% tag_name %]</a>[% ', ' UNLESS loop.last %]
178   [% ELSE %]
179   [% tag_id %][% ', ' UNLESS loop.last %]
180   [% END %]
181   [% old_facet = facet %]
182   [% IF loop.last -%]
183     </p>
184     </div> <!-- end ptags -->
185   [%- END %]
186 [% END %]
187
188 [% FOREACH providers %]
189   [% IF loop.first %]<div id="pdeps"><h2>Packages providing [% pkg %]</h2><dl>[% END %]
190     <dt>[% IF available %]<a href="[% make_url(name,'','source','') %]">[% name %]</a>[% ELSE %][% name %][% END %]</dt>
191     <dd>[% desc %]</dd>
192   [% '</dl></div>' IF loop.last %]
193 [% END %]
194 </div> <!-- pdesctab -->
195 [% END %]
196
197 [% FOREACH binaries %]
198   [% IF loop.first %]<div id="pbinaries">The following binary packages are built from this source package:<dl>[% END %]
199     <dt>[% IF available %]<a href="[% make_url(name,'','source','') %]">[% name %]</a>[% ELSE %][% name %][% END %]</dt>
200     <dd>[% desc %]</dd>    
201   [% '</dl></div>' IF loop.last %]
202 [% END %]
203
204 [% FOREACH relations %]
205   [% IF loop.first -%]
206     <div id="pdeps">
207     <h2>Other Packages Related to [% pkg %]</h2>
208
209     <table id="pdeplegend" summary="legend"><tr>
210     [% IF is_source %]
211     <td><img src="/Pics/adep.gif" alt="[adep]" width="16" height="16">= build-depends</td>
212     <td><img src="/Pics/idep.gif" alt="[idep]" width="16" height="16">= build-depends-indep</td>
213     [% ELSE %]
214     <td><img src="/Pics/dep.gif" alt="[dep]" width="16" height="16">= depends</td>
215     <td><img src="/Pics/rec.gif" alt="[rec]" width="16" height="16">= recommends</td>
216     <td><img src="/Pics/sug.gif" alt="[sug]" width="16" height="16">= suggests</td>
217     [% END %]
218     </tr></table>
219   [%- END %]
220
221   <ul class="ul[% id %]">
222   [% FOREACH terms %]
223     [% '<li>' UNLESS is_old_pkgs %]
224     [% FOREACH alternatives %]
225       [% '<dl>' IF loop.first %]
226       <dt>[% IF loop.first %]<img class="hidecss" src="/Pics/[% id %].gif" alt="[[% id %]]">[% ELSE %]or [% END %]
227         [% IF suite %]<a href="[% make_url(name,'','suite',suite,'source','') %]">[% name %]</a>[% ELSE %][% name %][% END %]
228         [% ' (' _ version _ ')' IF version %]
229         [% ' [' _ arch_str _ ']' IF arch_str %]</dt>
230       [%- IF !is_old_pkgs -%]
231         <dd>[% desc -%]
232         [%- IF providers.pkgs.size > 0 -%]
233           [% '<br>also a ' IF providers.also %]virtual package provided by
234           [% js_id = name %]
235             <span id="js_[% js_id %]" class="p_js_elem"></span> <span id="html_[% js_id %]">[% FOREACH provider IN providers.pkgs %]<a href="[% make_url(provider,'','suite',suite,'source','') %]">[% provider %]</a>[% ', ' UNLESS loop.last %][% END %]</span>
236         [% IF providers.pkgs.size > 10 %]
237         <script type="text/javascript">init_toggle_elem("[% js_id %]","[% providers.pkgs.size %] providing packages")</script>
238         [% END %]
239         [% END %]
240         </dd>
241       [% END %]
242       [% '</dl>' IF loop.last %]
243     [% END %]
244   [% END %]
245   </ul>
246
247   [% IF loop.last -%]
248     </div> <!-- end pdeps -->
249   [%- END %]
250 [% END %]
251
252 [% FOREACH d IN downloads %]
253   [% IF loop.first -%]
254     <div id="pdownload">
255     <h2>Download [% pkg %]</h2>
256     
257     <table summary="The download table links to the download of the package and a file overview. In addition it gives information about the package size and the installed size.">
258     <caption class="hidecss">Download for all available architectures</caption>
259     <tr><th>Architecture</th>[% '<th>Version</th>' IF versions.multiple %]<th>Package Size</th><th>Installed Size</th><th>Files</th></tr>
260   [%- END %]
261
262 <tr>
263 [% download_url = pkg _ '/' _ d.arch _ '/download'
264    filelist_url = pkg _ '/' _ d.arch _ '/filelist' %]
265 <th><a href="[% make_url(download_url) | uri %]">[% d.arch %]</a>
266 [%- SET a = d.archive; IF mirrors.$a.unofficial_port  %] <strong>(unofficial port)</strong>[% END %]</th>
267 [% vnorm = d.version.replace( '\+b\d+$', '' ); vlatest = version.replace( '\+b\d+$', '' );
268    vup = vnorm.replace( '-[^-]+$', '' ); vuplatest = vlatest.replace( '-[^-]+$', '' );
269    IF vnorm == vlatest;
270         version_class = 'vcurrent';
271    ELSIF vup == vuplatest;
272         version_class = 'volder';
273    ELSE;
274         version_class = 'vold';
275    END %]
276 [% "<td class='$version_class'>$d.version</td>" IF versions.multiple %]
277 <td class="size">[% d.pkgsize %]&nbsp;kB</td><td class="size">[% d.instsize %]&nbsp;kB</td>
278 <td>
279 [% IF d.contents_avail %]
280   [<a href="[% make_url(filelist_url) | uri %]">list of files</a>]
281 [% ELSE %]
282   no current information
283 [% END %]
284 </td>
285 </tr>
286
287   [% IF loop.last -%]
288     </table>
289
290     </div> <!-- end pdownload -->
291   [%- END %]
292 [% END %]
293
294 [% FOREACH srcfiles %]
295   [% IF loop.first -%]
296     <div id="pdownload">
297     <h2>Download [% pkg %]</h2>
298     
299     <table summary="Download information for the files of this source package">
300     <tr><th>File</th><th>Size (in kB)</th><th>md5sum</th></tr>
301   [%- END %]
302
303 <tr>
304 <td><a href="[% server _ path %]">[% filename %]</a></td>
305 <td>[% size %]</td>
306 <td class="md5sum">[% md5sum %]</td>
307 </tr>
308
309   [% IF loop.last -%]
310     </table>
311
312     </div> <!-- end pdownload -->
313   [%- END %]
314 [% END %]
315
316 <script type="text/javascript">init_tab_list("ptablist")</script>
317