Añade el plugin Redmine Git Hosting 5.0.0

This commit is contained in:
Manuel Cillero 2021-03-20 13:29:16 +01:00
parent cfa0d58b18
commit a3bddad233
458 changed files with 30396 additions and 1 deletions

View file

@ -0,0 +1,24 @@
module Projects
class Update < Base
def call
# Adjust daemon status
disable_git_daemon_if_not_public
resync
end
private
def disable_git_daemon_if_not_public
# Go through all gitolite repos and disable Git daemon if necessary
project.gitolite_repos.each do |repository|
repository.extra[:git_daemon] = false if repository.git_daemon_enabled? && !project.is_public
# Save GitExtra in all cases to trigger urls order consistency checks
repository.extra.save
end
end
def resync
gitolite_accessor.update_projects([project.id], options)
end
end
end