changeset 740:8873bc7c1af5 feature_318

Hack in simplistic download link
author Chris Cannam <chris.cannam@soundsoftware.ac.uk>
date Fri, 04 Nov 2011 17:56:58 +0000
parents 1ce6efe3db0e
children 496b3cfa2f36
files app/views/repositories/_navigation.rhtml
diffstat 1 files changed, 5 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/app/views/repositories/_navigation.rhtml	Fri Nov 04 16:42:49 2011 +0000
+++ b/app/views/repositories/_navigation.rhtml	Fri Nov 04 17:56:58 2011 +0000
@@ -4,6 +4,11 @@
 
 <%= link_to l(:label_statistics), {:action => 'stats', :id => @project}, :class => 'icon icon-stats' %>
 
+| <a href="/hg/<%= h(@project.identifier) %>/archive/<%= 
+    rev_text = @changeset.nil? ? @rev : format_revision(@changeset);
+    rev_text.blank? ? "tip" : rev_text 
+%>.zip">Download this revision</a>
+
 <% form_tag({:action => controller.action_name, :id => @project, :path => to_path_param(@path), :rev => ''}, {:method => :get, :id => 'revision_selector'}) do -%>
   <!-- Branches Dropdown -->
   <% if !@repository.branches.nil? && @repository.branches.length > 0 -%>