2017-12-18 18:58:20 -05:00
|
|
|
module Gitlab
|
|
|
|
module Git
|
|
|
|
class RemoteMirror
|
|
|
|
def initialize(repository, ref_name)
|
|
|
|
@repository = repository
|
|
|
|
@ref_name = ref_name
|
|
|
|
end
|
|
|
|
|
2018-01-17 18:25:16 -05:00
|
|
|
def update(only_branches_matching: [])
|
2018-06-25 05:37:24 -04:00
|
|
|
@repository.wrapped_gitaly_errors do
|
|
|
|
@repository.gitaly_remote_client.update_remote_mirror(@ref_name, only_branches_matching)
|
2017-12-18 18:58:20 -05:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|