/usr/share/koji-web/scripts/rpmlist.chtml is in koji-servers 1.10.0-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 | #from kojiweb import util
#include "includes/header.chtml"
#def getID()
#if $type == 'image'
imageID=$image.id #slurp
#else
buildrootID=$buildroot.id #slurp
#end if
#end def
#def getColspan()
#if $type == 'component'
colspan="3" #slurp
#elif $type == 'image'
colspan="2" #slurp
#else
#pass
#end if
#end def
#if $type == 'component'
<h4>Component RPMs of buildroot <a href="buildrootinfo?buildrootID=$buildroot.id">$buildroot.tag_name-$buildroot.id-$buildroot.repo_id</a></h4>
#elif $type == 'image'
<h4>RPMs installed in <a href="archiveinfo?archiveID=$image.id">$image.filename</a></h4>
#else
<h4>RPMs built in buildroot <a href="buildrootinfo?buildrootID=$buildroot.id">$buildroot.tag_name-$buildroot.id-$buildroot.repo_id</a></h4>
#end if
<table class="data-list">
<tr>
<td class="paginate" $getColspan()>
#if $len($rpmPages) > 1
<form class="pageJump" action="">
Page:
<select onchange="javascript: window.location = 'rpmlist?$getID()&start=' + this.value * $rpmRange + '$util.passthrough($self, 'order', 'type')';">
#for $pageNum in $rpmPages
<option value="$pageNum"#if $pageNum == $rpmCurrentPage then ' selected="selected"' else ''#>#echo $pageNum + 1#</option>
#end for
</select>
</form>
#end if
#if $rpmStart > 0
<a href="rpmlist?$getID()&start=#echo $rpmStart - $rpmRange #$util.passthrough($self, 'order', 'type')"><<<</a>
#end if
#if $totalRpms != 0
<strong>RPMs #echo $rpmStart + 1 # through #echo $rpmStart + $rpmCount # of $totalRpms</strong>
#end if
#if $rpmStart + $rpmCount < $totalRpms
<a href="rpmlist?$getID()&start=#echo $rpmStart + $rpmRange#$util.passthrough($self, 'order', 'type')">>>></a>
#end if
</td>
</tr>
<tr class="list-header">
<th><a href="rpmlist?$getID()&order=$util.toggleOrder($self, 'nvr')$util.passthrough($self, 'type')">NVR</a> $util.sortImage($self, 'nvr')</th>
#if $type in ['component', 'image']
<th><a href="rpmlist?$getID()&order=$util.toggleOrder($self, 'external_repo_name')$util.passthrough($self, 'type')">Origin</a> $util.sortImage($self, 'external_repo_name')</th>
#end if
#if $type == 'component'
<th><a href="rpmlist?$getID()&order=$util.toggleOrder($self, 'is_update')$util.passthrough($self, 'type')">Update?</a> $util.sortImage($self, 'is_update')</th>
#end if
</tr>
#if $len($rpms) > 0
#for $rpm in $rpms
<tr class="$util.rowToggle($self)">
#set $epoch = ($rpm.epoch != None and $str($rpm.epoch) + ':' or '')
<td><a href="rpminfo?rpmID=$rpm.id">$rpm.name-$epoch$rpm.version-$rpm.release.${rpm.arch}.rpm</a></td>
#if $type in ['component', 'image']
#if $rpm.external_repo_id == 0
<td>internal</td>
#else
<td><a href="externalrepoinfo?extrepoID=$rpm.external_repo_id">$rpm.external_repo_name</a></td>
#end if
#end if
#if $type == 'component'
#set $update = $rpm.is_update and 'yes' or 'no'
<td class="$update">$util.imageTag($update)</td>
#end if
</tr>
#end for
#else
<tr class="row-odd">
<td $getColspan()>No RPMs</td>
</tr>
#end if
<tr>
<td class="paginate" $getColspan()>
#if $len($rpmPages) > 1
<form class="pageJump" action="">
Page:
<select onchange="javascript: window.location = 'rpmlist?$getID()&start=' + this.value * $rpmRange + '$util.passthrough($self, 'order', 'type')';">
#for $pageNum in $rpmPages
<option value="$pageNum"#if $pageNum == $rpmCurrentPage then ' selected="selected"' else ''#>#echo $pageNum + 1#</option>
#end for
</select>
</form>
#end if
#if $rpmStart > 0
<a href="rpmlist?$getID()&start=#echo $rpmStart - $rpmRange #$util.passthrough($self, 'order', 'type')"><<<</a>
#end if
#if $totalRpms != 0
<strong>RPMs #echo $rpmStart + 1 # through #echo $rpmStart + $rpmCount # of $totalRpms</strong>
#end if
#if $rpmStart + $rpmCount < $totalRpms
<a href="rpmlist?$getID()&start=#echo $rpmStart + $rpmRange#$util.passthrough($self, 'order', 'type')">>>></a>
#end if
</td>
</tr>
</table>
#include "includes/footer.chtml"
|