diff --git a/app/views/gitolite_public_keys/edit.html.erb b/app/views/gitolite_public_keys/edit.html.erb index 78b7a15eb..b498dae37 100644 --- a/app/views/gitolite_public_keys/edit.html.erb +++ b/app/views/gitolite_public_keys/edit.html.erb @@ -1,4 +1,4 @@ -

<%= link_to l(:label_public_keys), public_keys_path %> » <%= h @gitolite_public_key %>

+

<%= link_to l(:label_public_keys), :controller=> "my", :action => "account" %> » <%= h @gitolite_public_key %>

<%= error_messages_for :gitolite_public_key %> diff --git a/lib/git_hosting.rb b/lib/git_hosting.rb index 8bcea3432..06e19b84f 100755 --- a/lib/git_hosting.rb +++ b/lib/git_hosting.rb @@ -344,6 +344,7 @@ def self.move_repository(old_name, new_name) end @@recursionCheck = false + @@projects_so_far= [] def self.update_repositories(projects, is_repo_delete) @@ -356,13 +357,14 @@ def self.update_repositories(projects, is_repo_delete) logger.debug "Updating repositories..." projects = (projects.is_a?(Array) ? projects : [projects]) - + + @@projects_so_far.each { |p| logger.info p.name } + projects= projects.select{|p| !@@projects_so_far.include?(p) } # Don't bother doing anything if none of the projects we've been handed have a Git repository unless projects.detect{|p| p.repository.is_a?(Repository::Git) }.nil? - #lock if !lock(5) @@recursionCheck = false @@ -383,7 +385,7 @@ def self.update_repositories(projects, is_repo_delete) changed = false projects.select{|p| p.repository.is_a?(Repository::Git)}.each do |project| - + @@projects_so_far << project repo_name = repository_name(project) #check for delete -- if delete we can just diff --git a/lib/git_hosting/patches/git_adapter_patch.rb b/lib/git_hosting/patches/git_adapter_patch.rb index d97624bd2..bcdf00a95 100644 --- a/lib/git_hosting/patches/git_adapter_patch.rb +++ b/lib/git_hosting/patches/git_adapter_patch.rb @@ -7,6 +7,7 @@ def self.included(base) unloadable end + base.send(:alias_method_chain, :entries, :entry_caching) begin base.send(:alias_method_chain, :scm_cmd, :sudo) rescue Exception =>e @@ -34,6 +35,11 @@ def client_command_with_sudo end end + def entries_with_entry_caching(path=nil, identifier=nil) + return @entries if @entries + @entries= entries_without_entry_caching(path, identifier) + @entries + end def scm_cmd_with_sudo(*args, &block)