Commit c9bd94b8 authored by Francisco Javier López's avatar Francisco Javier López 🔴 Committed by Zeger-Jan van de Weg

Add new RPC call to update submodule ref in repository

parent 43fb53d3
......@@ -137,6 +137,8 @@ It has these top-level messages:
UserSquashResponse
UserApplyPatchRequest
UserApplyPatchResponse
UserUpdateSubmoduleRequest
UserUpdateSubmoduleResponse
ListNewBlobsRequest
ListNewBlobsResponse
FindDefaultBranchNameRequest
......
This diff is collapsed.
......@@ -18,6 +18,7 @@ service OperationService {
rpc UserRebase(UserRebaseRequest) returns (UserRebaseResponse) {}
rpc UserSquash(UserSquashRequest) returns (UserSquashResponse) {}
rpc UserApplyPatch(stream UserApplyPatchRequest) returns (UserApplyPatchResponse) {}
rpc UserUpdateSubmodule(UserUpdateSubmoduleRequest) returns (UserUpdateSubmoduleResponse) {}
}
message UserCreateBranchRequest {
......@@ -260,3 +261,19 @@ message UserApplyPatchRequest {
message UserApplyPatchResponse {
OperationBranchUpdate branch_update = 1;
}
message UserUpdateSubmoduleRequest {
Repository repository = 1;
User user = 2;
string commit_sha = 3;
bytes branch = 4;
bytes submodule = 5;
bytes commit_message = 6;
}
message UserUpdateSubmoduleResponse {
OperationBranchUpdate branch_update = 1;
string pre_receive_error = 2;
string create_tree_error = 3;
string commit_error = 4;
}
......@@ -195,6 +195,20 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
add_message "gitaly.UserApplyPatchResponse" do
optional :branch_update, :message, 1, "gitaly.OperationBranchUpdate"
end
add_message "gitaly.UserUpdateSubmoduleRequest" do
optional :repository, :message, 1, "gitaly.Repository"
optional :user, :message, 2, "gitaly.User"
optional :commit_sha, :string, 3
optional :branch, :bytes, 4
optional :submodule, :bytes, 5
optional :commit_message, :bytes, 6
end
add_message "gitaly.UserUpdateSubmoduleResponse" do
optional :branch_update, :message, 1, "gitaly.OperationBranchUpdate"
optional :pre_receive_error, :string, 2
optional :create_tree_error, :string, 3
optional :commit_error, :string, 4
end
end
module Gitaly
......@@ -230,4 +244,6 @@ module Gitaly
UserApplyPatchRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("gitaly.UserApplyPatchRequest").msgclass
UserApplyPatchRequest::Header = Google::Protobuf::DescriptorPool.generated_pool.lookup("gitaly.UserApplyPatchRequest.Header").msgclass
UserApplyPatchResponse = Google::Protobuf::DescriptorPool.generated_pool.lookup("gitaly.UserApplyPatchResponse").msgclass
UserUpdateSubmoduleRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("gitaly.UserUpdateSubmoduleRequest").msgclass
UserUpdateSubmoduleResponse = Google::Protobuf::DescriptorPool.generated_pool.lookup("gitaly.UserUpdateSubmoduleResponse").msgclass
end
......@@ -27,6 +27,7 @@ module Gitaly
rpc :UserRebase, UserRebaseRequest, UserRebaseResponse
rpc :UserSquash, UserSquashRequest, UserSquashResponse
rpc :UserApplyPatch, stream(UserApplyPatchRequest), UserApplyPatchResponse
rpc :UserUpdateSubmodule, UserUpdateSubmoduleRequest, UserUpdateSubmoduleResponse
end
Stub = Service.rpc_stub_class
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment