Source

bloodhound-trac / trac / versioncontrol / templates / dir_entries.html

<!--! Template for generating rows corresponding to directory entries -->
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:py="http://genshi.edgewall.org/"
      xmlns:xi="http://www.w3.org/2001/XInclude" py:strip="">
  <py:for each="idx, entry in enumerate(dir.entries)"
          py:with="change = dir.changes[entry.created_rev];
                   chgset_context = change and context.child('changeset', change.rev, parent=repos.resource);
                   chgset_view = change and change.is_viewable(perm);
                   isdir = entry.kind == 'dir'">
    <tr class="${'odd' if idx % 2 else 'even'}">
      <td class="name">
        <a class="$entry.kind" title="${_('View Directory') if isdir else _('View File')}"
           href="${href.browser(reponame, entry.path, rev=stickyrev, 
                                order=order if order != 'name' else None, desc=desc)}">$entry.name</a>
      </td>
      <td class="size">
        <span title="${_('%(size)s bytes', size=entry.content_length)}">${pretty_size(entry.content_length)}</span>
        <a py:if="entry.raw_href" href="$entry.raw_href" class="${'trac-ziplink' if isdir else 'trac-rawlink'}"                       
           title="${_('Download as Zip archive') if isdir else _('Download')}">&#8203;</a>
      </td>
      <td class="rev">
        <a title="View Revision Log" href="${href.log(reponame, entry.path, rev=rev)}">${display_rev(entry.created_rev)}</a>
        <a title="View Changeset" class="chgset" href="${href.changeset(change.rev, reponame)}">&nbsp;</a>
      </td>
      <td class="age" style="${chgset_view and dir.timerange and 'border-color: rgb(%s,%s,%s)' %
                               dir.colorize_age(dir.timerange.relative(change.date)) or None}">
        ${pretty_dateinfo(change.date, dateonly=True) if chgset_view else '&ndash;'}
      </td>
      <td class="author">${authorinfo_short(change.author) if chgset_view else '&ndash;'}</td>
      <td class="change" py:choose="">
        <py:when test="chgset_view" py:choose="">
          <py:when test="wiki_format_messages">${wiki_to_oneliner(chgset_context, change.message, shorten=True)}</py:when>
          <py:otherwise>${shorten_line(change.message)}</py:otherwise>
        </py:when>
        <py:otherwise>&ndash;</py:otherwise>
      </td>
    </tr>
  </py:for>
</html>
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.