Remove satellites when moving namespace

This commit is contained in:
GitLab 2013-01-17 12:21:52 +02:00
parent b53ca0bcfe
commit 9115a4f92f

View file

@ -72,7 +72,14 @@ class Namespace < ActiveRecord::Base
raise "Already exists"
end
begin
# Remove satellite when moving repo
if path_was.present?
satellites_path = File.join(Gitlab.config.satellites.path, path_was)
FileUtils.rm_r( satellites_path, force: true )
end
FileUtils.mv( old_path, new_path )
send_update_instructions
@require_update_gitolite = true