diff options
Diffstat (limited to 'ruby/lib/gitaly_server/operations_service.rb')
-rw-r--r-- | ruby/lib/gitaly_server/operations_service.rb | 30 |
1 files changed, 0 insertions, 30 deletions
diff --git a/ruby/lib/gitaly_server/operations_service.rb b/ruby/lib/gitaly_server/operations_service.rb index 463fb0de0..9aae9b84a 100644 --- a/ruby/lib/gitaly_server/operations_service.rb +++ b/ruby/lib/gitaly_server/operations_service.rb @@ -20,36 +20,6 @@ module GitalyServer Gitaly::UserUpdateBranchResponse.new(pre_receive_error: set_utf8!(ex.message)) end - def user_cherry_pick(request, call) - repo = Gitlab::Git::Repository.from_gitaly(request.repository, call) - user = Gitlab::Git::User.from_gitaly(request.user) - commit = Gitlab::Git::Commit.new(repo, request.commit) - start_repository = Gitlab::Git::GitalyRemoteRepository.new(request.start_repository || request.repository, call) - - result = repo.cherry_pick( - user: user, - commit: commit, - branch_name: request.branch_name, - message: request.message.dup, - start_branch_name: request.start_branch_name.presence, - start_repository: start_repository, - dry_run: request.dry_run, - timestamp: request.timestamp - ) - - branch_update = branch_update_result(result) - Gitaly::UserCherryPickResponse.new(branch_update: branch_update) - rescue Gitlab::Git::Repository::CreateTreeError => e - Gitaly::UserCherryPickResponse.new( - create_tree_error: set_utf8!(e.message), - create_tree_error_code: e.error.upcase - ) - rescue Gitlab::Git::CommitError => e - Gitaly::UserCherryPickResponse.new(commit_error: set_utf8!(e.message)) - rescue Gitlab::Git::PreReceiveError => e - Gitaly::UserCherryPickResponse.new(pre_receive_error: set_utf8!(e.message)) - end - def user_revert(request, call) repo = Gitlab::Git::Repository.from_gitaly(request.repository, call) user = Gitlab::Git::User.from_gitaly(request.user) |