diff --git a/pkg/analyzer/commit_analyzer.go b/pkg/analyzer/commit_analyzer.go index 1a303c569042b3de0ac63eb2c94363214e365ea0..d492c675c242274952688dd91bee44e31f667f97 100644 --- a/pkg/analyzer/commit_analyzer.go +++ b/pkg/analyzer/commit_analyzer.go @@ -5,5 +5,8 @@ import ( ) type CommitAnalyzer interface { + Init(map[string]string) error + Name() string + Version() string Analyze([]*semrel.RawCommit) []*semrel.Commit } diff --git a/pkg/analyzer/commit_analyzer.pb.go b/pkg/analyzer/commit_analyzer.pb.go index 5f34b939c70a6259a8da8381ffb186ace7c4c4e5..6996c871fa755e4fd09e48a6ee51fe87d22c3690 100644 --- a/pkg/analyzer/commit_analyzer.pb.go +++ b/pkg/analyzer/commit_analyzer.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.25.0 -// protoc v3.12.3 +// protoc-gen-go v1.23.0 +// protoc v3.12.4 // source: pkg/analyzer/commit_analyzer.proto package analyzer @@ -26,6 +26,120 @@ const ( // of the legacy proto package is being used. const _ = proto.ProtoPackageIsVersion4 +type CommitAnalyzerInit struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *CommitAnalyzerInit) Reset() { + *x = CommitAnalyzerInit{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CommitAnalyzerInit) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CommitAnalyzerInit) ProtoMessage() {} + +func (x *CommitAnalyzerInit) ProtoReflect() protoreflect.Message { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use CommitAnalyzerInit.ProtoReflect.Descriptor instead. +func (*CommitAnalyzerInit) Descriptor() ([]byte, []int) { + return file_pkg_analyzer_commit_analyzer_proto_rawDescGZIP(), []int{0} +} + +type CommitAnalyzerName struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *CommitAnalyzerName) Reset() { + *x = CommitAnalyzerName{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CommitAnalyzerName) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CommitAnalyzerName) ProtoMessage() {} + +func (x *CommitAnalyzerName) ProtoReflect() protoreflect.Message { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use CommitAnalyzerName.ProtoReflect.Descriptor instead. +func (*CommitAnalyzerName) Descriptor() ([]byte, []int) { + return file_pkg_analyzer_commit_analyzer_proto_rawDescGZIP(), []int{1} +} + +type CommitAnalyzerVersion struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *CommitAnalyzerVersion) Reset() { + *x = CommitAnalyzerVersion{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CommitAnalyzerVersion) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CommitAnalyzerVersion) ProtoMessage() {} + +func (x *CommitAnalyzerVersion) ProtoReflect() protoreflect.Message { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use CommitAnalyzerVersion.ProtoReflect.Descriptor instead. +func (*CommitAnalyzerVersion) Descriptor() ([]byte, []int) { + return file_pkg_analyzer_commit_analyzer_proto_rawDescGZIP(), []int{2} +} + type AnalyzeCommits struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -35,7 +149,7 @@ type AnalyzeCommits struct { func (x *AnalyzeCommits) Reset() { *x = AnalyzeCommits{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[0] + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -48,7 +162,7 @@ func (x *AnalyzeCommits) String() string { func (*AnalyzeCommits) ProtoMessage() {} func (x *AnalyzeCommits) ProtoReflect() protoreflect.Message { - mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[0] + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[3] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -61,7 +175,271 @@ func (x *AnalyzeCommits) ProtoReflect() protoreflect.Message { // Deprecated: Use AnalyzeCommits.ProtoReflect.Descriptor instead. func (*AnalyzeCommits) Descriptor() ([]byte, []int) { - return file_pkg_analyzer_commit_analyzer_proto_rawDescGZIP(), []int{0} + return file_pkg_analyzer_commit_analyzer_proto_rawDescGZIP(), []int{3} +} + +type CommitAnalyzerInit_Request struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Config map[string]string `protobuf:"bytes,1,rep,name=config,proto3" json:"config,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` +} + +func (x *CommitAnalyzerInit_Request) Reset() { + *x = CommitAnalyzerInit_Request{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CommitAnalyzerInit_Request) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CommitAnalyzerInit_Request) ProtoMessage() {} + +func (x *CommitAnalyzerInit_Request) ProtoReflect() protoreflect.Message { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use CommitAnalyzerInit_Request.ProtoReflect.Descriptor instead. +func (*CommitAnalyzerInit_Request) Descriptor() ([]byte, []int) { + return file_pkg_analyzer_commit_analyzer_proto_rawDescGZIP(), []int{0, 0} +} + +func (x *CommitAnalyzerInit_Request) GetConfig() map[string]string { + if x != nil { + return x.Config + } + return nil +} + +type CommitAnalyzerInit_Response struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Error string `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"` +} + +func (x *CommitAnalyzerInit_Response) Reset() { + *x = CommitAnalyzerInit_Response{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CommitAnalyzerInit_Response) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CommitAnalyzerInit_Response) ProtoMessage() {} + +func (x *CommitAnalyzerInit_Response) ProtoReflect() protoreflect.Message { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use CommitAnalyzerInit_Response.ProtoReflect.Descriptor instead. +func (*CommitAnalyzerInit_Response) Descriptor() ([]byte, []int) { + return file_pkg_analyzer_commit_analyzer_proto_rawDescGZIP(), []int{0, 1} +} + +func (x *CommitAnalyzerInit_Response) GetError() string { + if x != nil { + return x.Error + } + return "" +} + +type CommitAnalyzerName_Request struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *CommitAnalyzerName_Request) Reset() { + *x = CommitAnalyzerName_Request{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CommitAnalyzerName_Request) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CommitAnalyzerName_Request) ProtoMessage() {} + +func (x *CommitAnalyzerName_Request) ProtoReflect() protoreflect.Message { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use CommitAnalyzerName_Request.ProtoReflect.Descriptor instead. +func (*CommitAnalyzerName_Request) Descriptor() ([]byte, []int) { + return file_pkg_analyzer_commit_analyzer_proto_rawDescGZIP(), []int{1, 0} +} + +type CommitAnalyzerName_Response struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` +} + +func (x *CommitAnalyzerName_Response) Reset() { + *x = CommitAnalyzerName_Response{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CommitAnalyzerName_Response) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CommitAnalyzerName_Response) ProtoMessage() {} + +func (x *CommitAnalyzerName_Response) ProtoReflect() protoreflect.Message { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[8] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use CommitAnalyzerName_Response.ProtoReflect.Descriptor instead. +func (*CommitAnalyzerName_Response) Descriptor() ([]byte, []int) { + return file_pkg_analyzer_commit_analyzer_proto_rawDescGZIP(), []int{1, 1} +} + +func (x *CommitAnalyzerName_Response) GetName() string { + if x != nil { + return x.Name + } + return "" +} + +type CommitAnalyzerVersion_Request struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *CommitAnalyzerVersion_Request) Reset() { + *x = CommitAnalyzerVersion_Request{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CommitAnalyzerVersion_Request) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CommitAnalyzerVersion_Request) ProtoMessage() {} + +func (x *CommitAnalyzerVersion_Request) ProtoReflect() protoreflect.Message { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[9] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use CommitAnalyzerVersion_Request.ProtoReflect.Descriptor instead. +func (*CommitAnalyzerVersion_Request) Descriptor() ([]byte, []int) { + return file_pkg_analyzer_commit_analyzer_proto_rawDescGZIP(), []int{2, 0} +} + +type CommitAnalyzerVersion_Response struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"` +} + +func (x *CommitAnalyzerVersion_Response) Reset() { + *x = CommitAnalyzerVersion_Response{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CommitAnalyzerVersion_Response) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CommitAnalyzerVersion_Response) ProtoMessage() {} + +func (x *CommitAnalyzerVersion_Response) ProtoReflect() protoreflect.Message { + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[10] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use CommitAnalyzerVersion_Response.ProtoReflect.Descriptor instead. +func (*CommitAnalyzerVersion_Response) Descriptor() ([]byte, []int) { + return file_pkg_analyzer_commit_analyzer_proto_rawDescGZIP(), []int{2, 1} +} + +func (x *CommitAnalyzerVersion_Response) GetVersion() string { + if x != nil { + return x.Version + } + return "" } type AnalyzeCommits_Request struct { @@ -75,7 +453,7 @@ type AnalyzeCommits_Request struct { func (x *AnalyzeCommits_Request) Reset() { *x = AnalyzeCommits_Request{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[1] + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -88,7 +466,7 @@ func (x *AnalyzeCommits_Request) String() string { func (*AnalyzeCommits_Request) ProtoMessage() {} func (x *AnalyzeCommits_Request) ProtoReflect() protoreflect.Message { - mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[1] + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[11] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -101,7 +479,7 @@ func (x *AnalyzeCommits_Request) ProtoReflect() protoreflect.Message { // Deprecated: Use AnalyzeCommits_Request.ProtoReflect.Descriptor instead. func (*AnalyzeCommits_Request) Descriptor() ([]byte, []int) { - return file_pkg_analyzer_commit_analyzer_proto_rawDescGZIP(), []int{0, 0} + return file_pkg_analyzer_commit_analyzer_proto_rawDescGZIP(), []int{3, 0} } func (x *AnalyzeCommits_Request) GetRawCommits() []*semrel.RawCommit { @@ -122,7 +500,7 @@ type AnalyzeCommits_Response struct { func (x *AnalyzeCommits_Response) Reset() { *x = AnalyzeCommits_Response{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[2] + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -135,7 +513,7 @@ func (x *AnalyzeCommits_Response) String() string { func (*AnalyzeCommits_Response) ProtoMessage() {} func (x *AnalyzeCommits_Response) ProtoReflect() protoreflect.Message { - mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[2] + mi := &file_pkg_analyzer_commit_analyzer_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -148,7 +526,7 @@ func (x *AnalyzeCommits_Response) ProtoReflect() protoreflect.Message { // Deprecated: Use AnalyzeCommits_Response.ProtoReflect.Descriptor instead. func (*AnalyzeCommits_Response) Descriptor() ([]byte, []int) { - return file_pkg_analyzer_commit_analyzer_proto_rawDescGZIP(), []int{0, 1} + return file_pkg_analyzer_commit_analyzer_proto_rawDescGZIP(), []int{3, 1} } func (x *AnalyzeCommits_Response) GetCommits() []*semrel.Commit { @@ -164,25 +542,59 @@ var file_pkg_analyzer_commit_analyzer_proto_rawDesc = []byte{ 0x0a, 0x22, 0x70, 0x6b, 0x67, 0x2f, 0x61, 0x6e, 0x61, 0x6c, 0x79, 0x7a, 0x65, 0x72, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x5f, 0x61, 0x6e, 0x61, 0x6c, 0x79, 0x7a, 0x65, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x18, 0x70, 0x6b, 0x67, 0x2f, 0x73, 0x65, 0x6d, 0x72, 0x65, 0x6c, - 0x2f, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x77, - 0x0a, 0x0e, 0x41, 0x6e, 0x61, 0x6c, 0x79, 0x7a, 0x65, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, - 0x1a, 0x36, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x2b, 0x0a, 0x0b, 0x72, - 0x61, 0x77, 0x5f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x0a, 0x2e, 0x52, 0x61, 0x77, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x0a, 0x72, 0x61, - 0x77, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x1a, 0x2d, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x21, 0x0a, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x18, - 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x07, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x07, - 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x32, 0x54, 0x0a, 0x14, 0x43, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x41, 0x6e, 0x61, 0x6c, 0x79, 0x7a, 0x65, 0x72, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x12, - 0x3c, 0x0a, 0x07, 0x41, 0x6e, 0x61, 0x6c, 0x79, 0x7a, 0x65, 0x12, 0x17, 0x2e, 0x41, 0x6e, 0x61, - 0x6c, 0x79, 0x7a, 0x65, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x2e, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x41, 0x6e, 0x61, 0x6c, 0x79, 0x7a, 0x65, 0x43, 0x6f, 0x6d, - 0x6d, 0x69, 0x74, 0x73, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x41, 0x5a, - 0x3f, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x6f, 0x2d, 0x73, + 0x2f, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xbe, + 0x01, 0x0a, 0x12, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x41, 0x6e, 0x61, 0x6c, 0x79, 0x7a, 0x65, + 0x72, 0x49, 0x6e, 0x69, 0x74, 0x1a, 0x85, 0x01, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x3f, 0x0a, 0x06, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x01, 0x20, 0x03, 0x28, + 0x0b, 0x32, 0x27, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x41, 0x6e, 0x61, 0x6c, 0x79, 0x7a, + 0x65, 0x72, 0x49, 0x6e, 0x69, 0x74, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x2e, 0x43, + 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x06, 0x63, 0x6f, 0x6e, 0x66, + 0x69, 0x67, 0x1a, 0x39, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x45, 0x6e, 0x74, 0x72, + 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, + 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x20, 0x0a, + 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x72, 0x72, + 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x22, + 0x3f, 0x0a, 0x12, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x41, 0x6e, 0x61, 0x6c, 0x79, 0x7a, 0x65, + 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x1a, 0x09, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x1e, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, + 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, + 0x22, 0x48, 0x0a, 0x15, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x41, 0x6e, 0x61, 0x6c, 0x79, 0x7a, + 0x65, 0x72, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x1a, 0x09, 0x0a, 0x07, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x24, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x18, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x22, 0x77, 0x0a, 0x0e, 0x41, 0x6e, + 0x61, 0x6c, 0x79, 0x7a, 0x65, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x1a, 0x36, 0x0a, 0x07, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x2b, 0x0a, 0x0b, 0x72, 0x61, 0x77, 0x5f, 0x63, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0a, 0x2e, 0x52, + 0x61, 0x77, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x0a, 0x72, 0x61, 0x77, 0x43, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x73, 0x1a, 0x2d, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x21, 0x0a, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, + 0x0b, 0x32, 0x07, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x07, 0x63, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x73, 0x32, 0xa6, 0x02, 0x0a, 0x14, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x41, 0x6e, + 0x61, 0x6c, 0x79, 0x7a, 0x65, 0x72, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x12, 0x41, 0x0a, 0x04, + 0x49, 0x6e, 0x69, 0x74, 0x12, 0x1b, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x41, 0x6e, 0x61, + 0x6c, 0x79, 0x7a, 0x65, 0x72, 0x49, 0x6e, 0x69, 0x74, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x1c, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x41, 0x6e, 0x61, 0x6c, 0x79, 0x7a, + 0x65, 0x72, 0x49, 0x6e, 0x69, 0x74, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x41, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1b, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, + 0x41, 0x6e, 0x61, 0x6c, 0x79, 0x7a, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x2e, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x41, 0x6e, 0x61, + 0x6c, 0x79, 0x7a, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x4a, 0x0a, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x1e, 0x2e, + 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x41, 0x6e, 0x61, 0x6c, 0x79, 0x7a, 0x65, 0x72, 0x56, 0x65, + 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, + 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x41, 0x6e, 0x61, 0x6c, 0x79, 0x7a, 0x65, 0x72, 0x56, 0x65, + 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3c, + 0x0a, 0x07, 0x41, 0x6e, 0x61, 0x6c, 0x79, 0x7a, 0x65, 0x12, 0x17, 0x2e, 0x41, 0x6e, 0x61, 0x6c, + 0x79, 0x7a, 0x65, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x41, 0x6e, 0x61, 0x6c, 0x79, 0x7a, 0x65, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x73, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x41, 0x5a, 0x3f, + 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x6f, 0x2d, 0x73, 0x65, + 0x6d, 0x61, 0x6e, 0x74, 0x69, 0x63, 0x2d, 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2f, 0x73, 0x65, 0x6d, 0x61, 0x6e, 0x74, 0x69, 0x63, 0x2d, 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2f, - 0x73, 0x65, 0x6d, 0x61, 0x6e, 0x74, 0x69, 0x63, 0x2d, 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, - 0x2f, 0x76, 0x32, 0x2f, 0x70, 0x6b, 0x67, 0x2f, 0x61, 0x6e, 0x61, 0x6c, 0x79, 0x7a, 0x65, 0x72, - 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x76, 0x32, 0x2f, 0x70, 0x6b, 0x67, 0x2f, 0x61, 0x6e, 0x61, 0x6c, 0x79, 0x7a, 0x65, 0x72, 0x62, + 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -197,24 +609,41 @@ func file_pkg_analyzer_commit_analyzer_proto_rawDescGZIP() []byte { return file_pkg_analyzer_commit_analyzer_proto_rawDescData } -var file_pkg_analyzer_commit_analyzer_proto_msgTypes = make([]protoimpl.MessageInfo, 3) +var file_pkg_analyzer_commit_analyzer_proto_msgTypes = make([]protoimpl.MessageInfo, 13) var file_pkg_analyzer_commit_analyzer_proto_goTypes = []interface{}{ - (*AnalyzeCommits)(nil), // 0: AnalyzeCommits - (*AnalyzeCommits_Request)(nil), // 1: AnalyzeCommits.Request - (*AnalyzeCommits_Response)(nil), // 2: AnalyzeCommits.Response - (*semrel.RawCommit)(nil), // 3: RawCommit - (*semrel.Commit)(nil), // 4: Commit + (*CommitAnalyzerInit)(nil), // 0: CommitAnalyzerInit + (*CommitAnalyzerName)(nil), // 1: CommitAnalyzerName + (*CommitAnalyzerVersion)(nil), // 2: CommitAnalyzerVersion + (*AnalyzeCommits)(nil), // 3: AnalyzeCommits + (*CommitAnalyzerInit_Request)(nil), // 4: CommitAnalyzerInit.Request + (*CommitAnalyzerInit_Response)(nil), // 5: CommitAnalyzerInit.Response + nil, // 6: CommitAnalyzerInit.Request.ConfigEntry + (*CommitAnalyzerName_Request)(nil), // 7: CommitAnalyzerName.Request + (*CommitAnalyzerName_Response)(nil), // 8: CommitAnalyzerName.Response + (*CommitAnalyzerVersion_Request)(nil), // 9: CommitAnalyzerVersion.Request + (*CommitAnalyzerVersion_Response)(nil), // 10: CommitAnalyzerVersion.Response + (*AnalyzeCommits_Request)(nil), // 11: AnalyzeCommits.Request + (*AnalyzeCommits_Response)(nil), // 12: AnalyzeCommits.Response + (*semrel.RawCommit)(nil), // 13: RawCommit + (*semrel.Commit)(nil), // 14: Commit } var file_pkg_analyzer_commit_analyzer_proto_depIdxs = []int32{ - 3, // 0: AnalyzeCommits.Request.raw_commits:type_name -> RawCommit - 4, // 1: AnalyzeCommits.Response.commits:type_name -> Commit - 1, // 2: CommitAnalyzerPlugin.Analyze:input_type -> AnalyzeCommits.Request - 2, // 3: CommitAnalyzerPlugin.Analyze:output_type -> AnalyzeCommits.Response - 3, // [3:4] is the sub-list for method output_type - 2, // [2:3] is the sub-list for method input_type - 2, // [2:2] is the sub-list for extension type_name - 2, // [2:2] is the sub-list for extension extendee - 0, // [0:2] is the sub-list for field type_name + 6, // 0: CommitAnalyzerInit.Request.config:type_name -> CommitAnalyzerInit.Request.ConfigEntry + 13, // 1: AnalyzeCommits.Request.raw_commits:type_name -> RawCommit + 14, // 2: AnalyzeCommits.Response.commits:type_name -> Commit + 4, // 3: CommitAnalyzerPlugin.Init:input_type -> CommitAnalyzerInit.Request + 7, // 4: CommitAnalyzerPlugin.Name:input_type -> CommitAnalyzerName.Request + 9, // 5: CommitAnalyzerPlugin.Version:input_type -> CommitAnalyzerVersion.Request + 11, // 6: CommitAnalyzerPlugin.Analyze:input_type -> AnalyzeCommits.Request + 5, // 7: CommitAnalyzerPlugin.Init:output_type -> CommitAnalyzerInit.Response + 8, // 8: CommitAnalyzerPlugin.Name:output_type -> CommitAnalyzerName.Response + 10, // 9: CommitAnalyzerPlugin.Version:output_type -> CommitAnalyzerVersion.Response + 12, // 10: CommitAnalyzerPlugin.Analyze:output_type -> AnalyzeCommits.Response + 7, // [7:11] is the sub-list for method output_type + 3, // [3:7] is the sub-list for method input_type + 3, // [3:3] is the sub-list for extension type_name + 3, // [3:3] is the sub-list for extension extendee + 0, // [0:3] is the sub-list for field type_name } func init() { file_pkg_analyzer_commit_analyzer_proto_init() } @@ -224,7 +653,7 @@ func file_pkg_analyzer_commit_analyzer_proto_init() { } if !protoimpl.UnsafeEnabled { file_pkg_analyzer_commit_analyzer_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*AnalyzeCommits); i { + switch v := v.(*CommitAnalyzerInit); i { case 0: return &v.state case 1: @@ -236,7 +665,7 @@ func file_pkg_analyzer_commit_analyzer_proto_init() { } } file_pkg_analyzer_commit_analyzer_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*AnalyzeCommits_Request); i { + switch v := v.(*CommitAnalyzerName); i { case 0: return &v.state case 1: @@ -248,6 +677,114 @@ func file_pkg_analyzer_commit_analyzer_proto_init() { } } file_pkg_analyzer_commit_analyzer_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CommitAnalyzerVersion); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_analyzer_commit_analyzer_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*AnalyzeCommits); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_analyzer_commit_analyzer_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CommitAnalyzerInit_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_analyzer_commit_analyzer_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CommitAnalyzerInit_Response); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_analyzer_commit_analyzer_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CommitAnalyzerName_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_analyzer_commit_analyzer_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CommitAnalyzerName_Response); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_analyzer_commit_analyzer_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CommitAnalyzerVersion_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_analyzer_commit_analyzer_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CommitAnalyzerVersion_Response); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_analyzer_commit_analyzer_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*AnalyzeCommits_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_analyzer_commit_analyzer_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*AnalyzeCommits_Response); i { case 0: return &v.state @@ -266,7 +803,7 @@ func file_pkg_analyzer_commit_analyzer_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_pkg_analyzer_commit_analyzer_proto_rawDesc, NumEnums: 0, - NumMessages: 3, + NumMessages: 13, NumExtensions: 0, NumServices: 1, }, diff --git a/pkg/analyzer/commit_analyzer.proto b/pkg/analyzer/commit_analyzer.proto index 040d95343b0343b7588e098b4148b6e0ab6d10bd..d66103d9a9969a1dad86178a44263965b886d04f 100644 --- a/pkg/analyzer/commit_analyzer.proto +++ b/pkg/analyzer/commit_analyzer.proto @@ -3,6 +3,29 @@ option go_package = "github.com/go-semantic-release/semantic-release/v2/pkg/anal import "pkg/semrel/structs.proto"; +message CommitAnalyzerInit { + message Request { + map<string, string> config = 1; + } + message Response { + string error = 1; + } +} + +message CommitAnalyzerName { + message Request {} + message Response { + string name = 1; + } +} + +message CommitAnalyzerVersion { + message Request {} + message Response { + string version = 1; + } +} + message AnalyzeCommits { message Request { repeated RawCommit raw_commits = 1; @@ -12,6 +35,10 @@ message AnalyzeCommits { } } + service CommitAnalyzerPlugin { + rpc Init(CommitAnalyzerInit.Request) returns (CommitAnalyzerInit.Response); + rpc Name(CommitAnalyzerName.Request) returns (CommitAnalyzerName.Response); + rpc Version(CommitAnalyzerVersion.Request) returns (CommitAnalyzerVersion.Response); rpc Analyze(AnalyzeCommits.Request) returns (AnalyzeCommits.Response); } diff --git a/pkg/analyzer/commit_analyzer_grpc.pb.go b/pkg/analyzer/commit_analyzer_grpc.pb.go index 7d437101ff39697496211a4c1cb72270c38e42ea..729e1d86fa74b05bec0a2fa893b57f8eaa28f8b2 100644 --- a/pkg/analyzer/commit_analyzer_grpc.pb.go +++ b/pkg/analyzer/commit_analyzer_grpc.pb.go @@ -17,6 +17,9 @@ const _ = grpc.SupportPackageIsVersion6 // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. type CommitAnalyzerPluginClient interface { + Init(ctx context.Context, in *CommitAnalyzerInit_Request, opts ...grpc.CallOption) (*CommitAnalyzerInit_Response, error) + Name(ctx context.Context, in *CommitAnalyzerName_Request, opts ...grpc.CallOption) (*CommitAnalyzerName_Response, error) + Version(ctx context.Context, in *CommitAnalyzerVersion_Request, opts ...grpc.CallOption) (*CommitAnalyzerVersion_Response, error) Analyze(ctx context.Context, in *AnalyzeCommits_Request, opts ...grpc.CallOption) (*AnalyzeCommits_Response, error) } @@ -28,6 +31,33 @@ func NewCommitAnalyzerPluginClient(cc grpc.ClientConnInterface) CommitAnalyzerPl return &commitAnalyzerPluginClient{cc} } +func (c *commitAnalyzerPluginClient) Init(ctx context.Context, in *CommitAnalyzerInit_Request, opts ...grpc.CallOption) (*CommitAnalyzerInit_Response, error) { + out := new(CommitAnalyzerInit_Response) + err := c.cc.Invoke(ctx, "/CommitAnalyzerPlugin/Init", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *commitAnalyzerPluginClient) Name(ctx context.Context, in *CommitAnalyzerName_Request, opts ...grpc.CallOption) (*CommitAnalyzerName_Response, error) { + out := new(CommitAnalyzerName_Response) + err := c.cc.Invoke(ctx, "/CommitAnalyzerPlugin/Name", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *commitAnalyzerPluginClient) Version(ctx context.Context, in *CommitAnalyzerVersion_Request, opts ...grpc.CallOption) (*CommitAnalyzerVersion_Response, error) { + out := new(CommitAnalyzerVersion_Response) + err := c.cc.Invoke(ctx, "/CommitAnalyzerPlugin/Version", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *commitAnalyzerPluginClient) Analyze(ctx context.Context, in *AnalyzeCommits_Request, opts ...grpc.CallOption) (*AnalyzeCommits_Response, error) { out := new(AnalyzeCommits_Response) err := c.cc.Invoke(ctx, "/CommitAnalyzerPlugin/Analyze", in, out, opts...) @@ -41,6 +71,9 @@ func (c *commitAnalyzerPluginClient) Analyze(ctx context.Context, in *AnalyzeCom // All implementations must embed UnimplementedCommitAnalyzerPluginServer // for forward compatibility type CommitAnalyzerPluginServer interface { + Init(context.Context, *CommitAnalyzerInit_Request) (*CommitAnalyzerInit_Response, error) + Name(context.Context, *CommitAnalyzerName_Request) (*CommitAnalyzerName_Response, error) + Version(context.Context, *CommitAnalyzerVersion_Request) (*CommitAnalyzerVersion_Response, error) Analyze(context.Context, *AnalyzeCommits_Request) (*AnalyzeCommits_Response, error) mustEmbedUnimplementedCommitAnalyzerPluginServer() } @@ -49,6 +82,15 @@ type CommitAnalyzerPluginServer interface { type UnimplementedCommitAnalyzerPluginServer struct { } +func (*UnimplementedCommitAnalyzerPluginServer) Init(context.Context, *CommitAnalyzerInit_Request) (*CommitAnalyzerInit_Response, error) { + return nil, status.Errorf(codes.Unimplemented, "method Init not implemented") +} +func (*UnimplementedCommitAnalyzerPluginServer) Name(context.Context, *CommitAnalyzerName_Request) (*CommitAnalyzerName_Response, error) { + return nil, status.Errorf(codes.Unimplemented, "method Name not implemented") +} +func (*UnimplementedCommitAnalyzerPluginServer) Version(context.Context, *CommitAnalyzerVersion_Request) (*CommitAnalyzerVersion_Response, error) { + return nil, status.Errorf(codes.Unimplemented, "method Version not implemented") +} func (*UnimplementedCommitAnalyzerPluginServer) Analyze(context.Context, *AnalyzeCommits_Request) (*AnalyzeCommits_Response, error) { return nil, status.Errorf(codes.Unimplemented, "method Analyze not implemented") } @@ -58,6 +100,60 @@ func RegisterCommitAnalyzerPluginServer(s *grpc.Server, srv CommitAnalyzerPlugin s.RegisterService(&_CommitAnalyzerPlugin_serviceDesc, srv) } +func _CommitAnalyzerPlugin_Init_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(CommitAnalyzerInit_Request) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(CommitAnalyzerPluginServer).Init(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/CommitAnalyzerPlugin/Init", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(CommitAnalyzerPluginServer).Init(ctx, req.(*CommitAnalyzerInit_Request)) + } + return interceptor(ctx, in, info, handler) +} + +func _CommitAnalyzerPlugin_Name_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(CommitAnalyzerName_Request) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(CommitAnalyzerPluginServer).Name(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/CommitAnalyzerPlugin/Name", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(CommitAnalyzerPluginServer).Name(ctx, req.(*CommitAnalyzerName_Request)) + } + return interceptor(ctx, in, info, handler) +} + +func _CommitAnalyzerPlugin_Version_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(CommitAnalyzerVersion_Request) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(CommitAnalyzerPluginServer).Version(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/CommitAnalyzerPlugin/Version", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(CommitAnalyzerPluginServer).Version(ctx, req.(*CommitAnalyzerVersion_Request)) + } + return interceptor(ctx, in, info, handler) +} + func _CommitAnalyzerPlugin_Analyze_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(AnalyzeCommits_Request) if err := dec(in); err != nil { @@ -80,6 +176,18 @@ var _CommitAnalyzerPlugin_serviceDesc = grpc.ServiceDesc{ ServiceName: "CommitAnalyzerPlugin", HandlerType: (*CommitAnalyzerPluginServer)(nil), Methods: []grpc.MethodDesc{ + { + MethodName: "Init", + Handler: _CommitAnalyzerPlugin_Init_Handler, + }, + { + MethodName: "Name", + Handler: _CommitAnalyzerPlugin_Name_Handler, + }, + { + MethodName: "Version", + Handler: _CommitAnalyzerPlugin_Version_Handler, + }, { MethodName: "Analyze", Handler: _CommitAnalyzerPlugin_Analyze_Handler, diff --git a/pkg/analyzer/commit_analyzer_wrapper.go b/pkg/analyzer/commit_analyzer_wrapper.go index c0fced084169433928f105650e737c0ca895c363..b919b2c5c9dfde8c3d3171aa61918e4c2415c6aa 100644 --- a/pkg/analyzer/commit_analyzer_wrapper.go +++ b/pkg/analyzer/commit_analyzer_wrapper.go @@ -2,6 +2,7 @@ package analyzer import ( "context" + "errors" "github.com/go-semantic-release/semantic-release/v2/pkg/semrel" ) @@ -13,6 +14,23 @@ type CommitAnalyzerServer struct { UnimplementedCommitAnalyzerPluginServer } +func (c *CommitAnalyzerServer) Init(ctx context.Context, request *CommitAnalyzerInit_Request) (*CommitAnalyzerInit_Response, error) { + err := c.Impl.Init(request.Config) + res := &CommitAnalyzerInit_Response{} + if err != nil { + res.Error = err.Error() + } + return res, nil +} + +func (c *CommitAnalyzerServer) Name(ctx context.Context, request *CommitAnalyzerName_Request) (*CommitAnalyzerName_Response, error) { + return &CommitAnalyzerName_Response{Name: c.Impl.Name()}, nil +} + +func (c *CommitAnalyzerServer) Version(ctx context.Context, request *CommitAnalyzerVersion_Request) (*CommitAnalyzerVersion_Response, error) { + return &CommitAnalyzerVersion_Response{Version: c.Impl.Version()}, nil +} + func (c *CommitAnalyzerServer) Analyze(ctx context.Context, request *AnalyzeCommits_Request) (*AnalyzeCommits_Response, error) { return &AnalyzeCommits_Response{ Commits: c.Impl.Analyze(request.RawCommits), @@ -23,6 +41,35 @@ type CommitAnalyzerClient struct { Impl CommitAnalyzerPluginClient } +func (c *CommitAnalyzerClient) Init(m map[string]string) error { + res, err := c.Impl.Init(context.Background(), &CommitAnalyzerInit_Request{ + Config: m, + }) + if err != nil { + return err + } + if res.Error != "" { + return errors.New(res.Error) + } + return nil +} + +func (c *CommitAnalyzerClient) Name() string { + res, err := c.Impl.Name(context.Background(), &CommitAnalyzerName_Request{}) + if err != nil { + panic(err) + } + return res.Name +} + +func (c *CommitAnalyzerClient) Version() string { + res, err := c.Impl.Version(context.Background(), &CommitAnalyzerVersion_Request{}) + if err != nil { + panic(err) + } + return res.Version +} + func (c *CommitAnalyzerClient) Analyze(commits []*semrel.RawCommit) []*semrel.Commit { res, err := c.Impl.Analyze(context.Background(), &AnalyzeCommits_Request{RawCommits: commits}) if err != nil { diff --git a/pkg/condition/ci_condition.go b/pkg/condition/ci_condition.go index e92348ecf44ba9cb19fc45a6b0c7f1c110684dd1..ef5234ea875a7434cebcfd830c9b6535ff544880 100644 --- a/pkg/condition/ci_condition.go +++ b/pkg/condition/ci_condition.go @@ -2,6 +2,7 @@ package condition type CICondition interface { Name() string + Version() string RunCondition(map[string]string) error GetCurrentBranch() string GetCurrentSHA() string diff --git a/pkg/condition/ci_condition.pb.go b/pkg/condition/ci_condition.pb.go index d3937a016fd95e640f1eb376c43a431f9d23cd4e..07b0463802fa08c1da5e460a5497df4d1003b001 100644 --- a/pkg/condition/ci_condition.pb.go +++ b/pkg/condition/ci_condition.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.25.0 -// protoc v3.12.3 +// protoc-gen-go v1.23.0 +// protoc v3.12.4 // source: pkg/condition/ci_condition.proto package condition @@ -63,6 +63,44 @@ func (*CIName) Descriptor() ([]byte, []int) { return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{0} } +type CIVersion struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *CIVersion) Reset() { + *x = CIVersion{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_condition_ci_condition_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CIVersion) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CIVersion) ProtoMessage() {} + +func (x *CIVersion) ProtoReflect() protoreflect.Message { + mi := &file_pkg_condition_ci_condition_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use CIVersion.ProtoReflect.Descriptor instead. +func (*CIVersion) Descriptor() ([]byte, []int) { + return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{1} +} + type RunCondition struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -72,7 +110,7 @@ type RunCondition struct { func (x *RunCondition) Reset() { *x = RunCondition{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[1] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[2] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -85,7 +123,7 @@ func (x *RunCondition) String() string { func (*RunCondition) ProtoMessage() {} func (x *RunCondition) ProtoReflect() protoreflect.Message { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[1] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[2] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -98,7 +136,7 @@ func (x *RunCondition) ProtoReflect() protoreflect.Message { // Deprecated: Use RunCondition.ProtoReflect.Descriptor instead. func (*RunCondition) Descriptor() ([]byte, []int) { - return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{1} + return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{2} } type GetCurrentBranch struct { @@ -110,7 +148,7 @@ type GetCurrentBranch struct { func (x *GetCurrentBranch) Reset() { *x = GetCurrentBranch{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[2] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -123,7 +161,7 @@ func (x *GetCurrentBranch) String() string { func (*GetCurrentBranch) ProtoMessage() {} func (x *GetCurrentBranch) ProtoReflect() protoreflect.Message { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[2] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[3] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -136,7 +174,7 @@ func (x *GetCurrentBranch) ProtoReflect() protoreflect.Message { // Deprecated: Use GetCurrentBranch.ProtoReflect.Descriptor instead. func (*GetCurrentBranch) Descriptor() ([]byte, []int) { - return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{2} + return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{3} } type GetCurrentSHA struct { @@ -148,7 +186,7 @@ type GetCurrentSHA struct { func (x *GetCurrentSHA) Reset() { *x = GetCurrentSHA{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[3] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -161,7 +199,7 @@ func (x *GetCurrentSHA) String() string { func (*GetCurrentSHA) ProtoMessage() {} func (x *GetCurrentSHA) ProtoReflect() protoreflect.Message { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[3] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[4] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -174,7 +212,7 @@ func (x *GetCurrentSHA) ProtoReflect() protoreflect.Message { // Deprecated: Use GetCurrentSHA.ProtoReflect.Descriptor instead. func (*GetCurrentSHA) Descriptor() ([]byte, []int) { - return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{3} + return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{4} } type CIName_Request struct { @@ -186,7 +224,7 @@ type CIName_Request struct { func (x *CIName_Request) Reset() { *x = CIName_Request{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[4] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -199,7 +237,7 @@ func (x *CIName_Request) String() string { func (*CIName_Request) ProtoMessage() {} func (x *CIName_Request) ProtoReflect() protoreflect.Message { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[4] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[5] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -220,13 +258,13 @@ type CIName_Response struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Value string `protobuf:"bytes,1,opt,name=value,proto3" json:"value,omitempty"` + Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` } func (x *CIName_Response) Reset() { *x = CIName_Response{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[5] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -239,7 +277,7 @@ func (x *CIName_Response) String() string { func (*CIName_Response) ProtoMessage() {} func (x *CIName_Response) ProtoReflect() protoreflect.Message { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[5] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[6] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -255,9 +293,94 @@ func (*CIName_Response) Descriptor() ([]byte, []int) { return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{0, 1} } -func (x *CIName_Response) GetValue() string { +func (x *CIName_Response) GetName() string { if x != nil { - return x.Value + return x.Name + } + return "" +} + +type CIVersion_Request struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *CIVersion_Request) Reset() { + *x = CIVersion_Request{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_condition_ci_condition_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CIVersion_Request) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CIVersion_Request) ProtoMessage() {} + +func (x *CIVersion_Request) ProtoReflect() protoreflect.Message { + mi := &file_pkg_condition_ci_condition_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use CIVersion_Request.ProtoReflect.Descriptor instead. +func (*CIVersion_Request) Descriptor() ([]byte, []int) { + return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{1, 0} +} + +type CIVersion_Response struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"` +} + +func (x *CIVersion_Response) Reset() { + *x = CIVersion_Response{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_condition_ci_condition_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *CIVersion_Response) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*CIVersion_Response) ProtoMessage() {} + +func (x *CIVersion_Response) ProtoReflect() protoreflect.Message { + mi := &file_pkg_condition_ci_condition_proto_msgTypes[8] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use CIVersion_Response.ProtoReflect.Descriptor instead. +func (*CIVersion_Response) Descriptor() ([]byte, []int) { + return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{1, 1} +} + +func (x *CIVersion_Response) GetVersion() string { + if x != nil { + return x.Version } return "" } @@ -273,7 +396,7 @@ type RunCondition_Request struct { func (x *RunCondition_Request) Reset() { *x = RunCondition_Request{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[6] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -286,7 +409,7 @@ func (x *RunCondition_Request) String() string { func (*RunCondition_Request) ProtoMessage() {} func (x *RunCondition_Request) ProtoReflect() protoreflect.Message { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[6] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[9] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -299,7 +422,7 @@ func (x *RunCondition_Request) ProtoReflect() protoreflect.Message { // Deprecated: Use RunCondition_Request.ProtoReflect.Descriptor instead. func (*RunCondition_Request) Descriptor() ([]byte, []int) { - return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{1, 0} + return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{2, 0} } func (x *RunCondition_Request) GetValue() map[string]string { @@ -320,7 +443,7 @@ type RunCondition_Response struct { func (x *RunCondition_Response) Reset() { *x = RunCondition_Response{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[7] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -333,7 +456,7 @@ func (x *RunCondition_Response) String() string { func (*RunCondition_Response) ProtoMessage() {} func (x *RunCondition_Response) ProtoReflect() protoreflect.Message { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[7] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -346,7 +469,7 @@ func (x *RunCondition_Response) ProtoReflect() protoreflect.Message { // Deprecated: Use RunCondition_Response.ProtoReflect.Descriptor instead. func (*RunCondition_Response) Descriptor() ([]byte, []int) { - return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{1, 1} + return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{2, 1} } func (x *RunCondition_Response) GetError() string { @@ -365,7 +488,7 @@ type GetCurrentBranch_Request struct { func (x *GetCurrentBranch_Request) Reset() { *x = GetCurrentBranch_Request{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[9] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -378,7 +501,7 @@ func (x *GetCurrentBranch_Request) String() string { func (*GetCurrentBranch_Request) ProtoMessage() {} func (x *GetCurrentBranch_Request) ProtoReflect() protoreflect.Message { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[9] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -391,7 +514,7 @@ func (x *GetCurrentBranch_Request) ProtoReflect() protoreflect.Message { // Deprecated: Use GetCurrentBranch_Request.ProtoReflect.Descriptor instead. func (*GetCurrentBranch_Request) Descriptor() ([]byte, []int) { - return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{2, 0} + return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{3, 0} } type GetCurrentBranch_Response struct { @@ -405,7 +528,7 @@ type GetCurrentBranch_Response struct { func (x *GetCurrentBranch_Response) Reset() { *x = GetCurrentBranch_Response{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[10] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -418,7 +541,7 @@ func (x *GetCurrentBranch_Response) String() string { func (*GetCurrentBranch_Response) ProtoMessage() {} func (x *GetCurrentBranch_Response) ProtoReflect() protoreflect.Message { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[10] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[13] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -431,7 +554,7 @@ func (x *GetCurrentBranch_Response) ProtoReflect() protoreflect.Message { // Deprecated: Use GetCurrentBranch_Response.ProtoReflect.Descriptor instead. func (*GetCurrentBranch_Response) Descriptor() ([]byte, []int) { - return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{2, 1} + return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{3, 1} } func (x *GetCurrentBranch_Response) GetValue() string { @@ -450,7 +573,7 @@ type GetCurrentSHA_Request struct { func (x *GetCurrentSHA_Request) Reset() { *x = GetCurrentSHA_Request{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[11] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -463,7 +586,7 @@ func (x *GetCurrentSHA_Request) String() string { func (*GetCurrentSHA_Request) ProtoMessage() {} func (x *GetCurrentSHA_Request) ProtoReflect() protoreflect.Message { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[11] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[14] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -476,7 +599,7 @@ func (x *GetCurrentSHA_Request) ProtoReflect() protoreflect.Message { // Deprecated: Use GetCurrentSHA_Request.ProtoReflect.Descriptor instead. func (*GetCurrentSHA_Request) Descriptor() ([]byte, []int) { - return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{3, 0} + return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{4, 0} } type GetCurrentSHA_Response struct { @@ -490,7 +613,7 @@ type GetCurrentSHA_Response struct { func (x *GetCurrentSHA_Response) Reset() { *x = GetCurrentSHA_Response{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[12] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -503,7 +626,7 @@ func (x *GetCurrentSHA_Response) String() string { func (*GetCurrentSHA_Response) ProtoMessage() {} func (x *GetCurrentSHA_Response) ProtoReflect() protoreflect.Message { - mi := &file_pkg_condition_ci_condition_proto_msgTypes[12] + mi := &file_pkg_condition_ci_condition_proto_msgTypes[15] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -516,7 +639,7 @@ func (x *GetCurrentSHA_Response) ProtoReflect() protoreflect.Message { // Deprecated: Use GetCurrentSHA_Response.ProtoReflect.Descriptor instead. func (*GetCurrentSHA_Response) Descriptor() ([]byte, []int) { - return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{3, 1} + return file_pkg_condition_ci_condition_proto_rawDescGZIP(), []int{4, 1} } func (x *GetCurrentSHA_Response) GetValue() string { @@ -531,32 +654,39 @@ var File_pkg_condition_ci_condition_proto protoreflect.FileDescriptor var file_pkg_condition_ci_condition_proto_rawDesc = []byte{ 0x0a, 0x20, 0x70, 0x6b, 0x67, 0x2f, 0x63, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x69, 0x5f, 0x63, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x22, 0x35, 0x0a, 0x06, 0x43, 0x49, 0x4e, 0x61, 0x6d, 0x65, 0x1a, 0x09, 0x0a, 0x07, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0xad, 0x01, 0x0a, 0x0c, 0x52, 0x75, - 0x6e, 0x43, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x1a, 0x7b, 0x0a, 0x07, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x36, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, - 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x52, 0x75, 0x6e, 0x43, 0x6f, 0x6e, 0x64, 0x69, 0x74, - 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x2e, 0x56, 0x61, 0x6c, 0x75, - 0x65, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x1a, 0x38, 0x0a, - 0x0a, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, - 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, - 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, - 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x20, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x22, 0x3f, 0x0a, 0x10, 0x47, 0x65, 0x74, - 0x43, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x42, 0x72, 0x61, 0x6e, 0x63, 0x68, 0x1a, 0x09, 0x0a, - 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3c, 0x0a, 0x0d, 0x47, 0x65, - 0x74, 0x43, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x53, 0x48, 0x41, 0x1a, 0x09, 0x0a, 0x07, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x32, 0x8a, 0x02, 0x0a, 0x11, 0x43, 0x49, 0x43, - 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x12, 0x29, - 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x0f, 0x2e, 0x43, 0x49, 0x4e, 0x61, 0x6d, 0x65, 0x2e, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x10, 0x2e, 0x43, 0x49, 0x4e, 0x61, 0x6d, 0x65, + 0x74, 0x6f, 0x22, 0x33, 0x0a, 0x06, 0x43, 0x49, 0x4e, 0x61, 0x6d, 0x65, 0x1a, 0x09, 0x0a, 0x07, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x3c, 0x0a, 0x09, 0x43, 0x49, 0x56, 0x65, 0x72, + 0x73, 0x69, 0x6f, 0x6e, 0x1a, 0x09, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x24, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x76, + 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x76, 0x65, + 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x22, 0xad, 0x01, 0x0a, 0x0c, 0x52, 0x75, 0x6e, 0x43, 0x6f, 0x6e, + 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x1a, 0x7b, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x36, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x20, 0x2e, 0x52, 0x75, 0x6e, 0x43, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x2e, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x2e, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x45, 0x6e, 0x74, + 0x72, 0x79, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x1a, 0x38, 0x0a, 0x0a, 0x56, 0x61, 0x6c, + 0x75, 0x65, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, + 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, + 0x02, 0x38, 0x01, 0x1a, 0x20, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x14, 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, + 0x65, 0x72, 0x72, 0x6f, 0x72, 0x22, 0x3f, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x43, 0x75, 0x72, 0x72, + 0x65, 0x6e, 0x74, 0x42, 0x72, 0x61, 0x6e, 0x63, 0x68, 0x1a, 0x09, 0x0a, 0x07, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3c, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x43, 0x75, 0x72, + 0x72, 0x65, 0x6e, 0x74, 0x53, 0x48, 0x41, 0x1a, 0x09, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x20, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x14, + 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, + 0x61, 0x6c, 0x75, 0x65, 0x32, 0xbe, 0x02, 0x0a, 0x11, 0x43, 0x49, 0x43, 0x6f, 0x6e, 0x64, 0x69, + 0x74, 0x69, 0x6f, 0x6e, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x12, 0x29, 0x0a, 0x04, 0x4e, 0x61, + 0x6d, 0x65, 0x12, 0x0f, 0x2e, 0x43, 0x49, 0x4e, 0x61, 0x6d, 0x65, 0x2e, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x10, 0x2e, 0x43, 0x49, 0x4e, 0x61, 0x6d, 0x65, 0x2e, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x32, 0x0a, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, + 0x12, 0x12, 0x2e, 0x43, 0x49, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x13, 0x2e, 0x43, 0x49, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3d, 0x0a, 0x0c, 0x52, 0x75, 0x6e, 0x43, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x15, 0x2e, 0x52, 0x75, 0x6e, 0x43, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, @@ -590,34 +720,39 @@ func file_pkg_condition_ci_condition_proto_rawDescGZIP() []byte { return file_pkg_condition_ci_condition_proto_rawDescData } -var file_pkg_condition_ci_condition_proto_msgTypes = make([]protoimpl.MessageInfo, 13) +var file_pkg_condition_ci_condition_proto_msgTypes = make([]protoimpl.MessageInfo, 16) var file_pkg_condition_ci_condition_proto_goTypes = []interface{}{ (*CIName)(nil), // 0: CIName - (*RunCondition)(nil), // 1: RunCondition - (*GetCurrentBranch)(nil), // 2: GetCurrentBranch - (*GetCurrentSHA)(nil), // 3: GetCurrentSHA - (*CIName_Request)(nil), // 4: CIName.Request - (*CIName_Response)(nil), // 5: CIName.Response - (*RunCondition_Request)(nil), // 6: RunCondition.Request - (*RunCondition_Response)(nil), // 7: RunCondition.Response - nil, // 8: RunCondition.Request.ValueEntry - (*GetCurrentBranch_Request)(nil), // 9: GetCurrentBranch.Request - (*GetCurrentBranch_Response)(nil), // 10: GetCurrentBranch.Response - (*GetCurrentSHA_Request)(nil), // 11: GetCurrentSHA.Request - (*GetCurrentSHA_Response)(nil), // 12: GetCurrentSHA.Response + (*CIVersion)(nil), // 1: CIVersion + (*RunCondition)(nil), // 2: RunCondition + (*GetCurrentBranch)(nil), // 3: GetCurrentBranch + (*GetCurrentSHA)(nil), // 4: GetCurrentSHA + (*CIName_Request)(nil), // 5: CIName.Request + (*CIName_Response)(nil), // 6: CIName.Response + (*CIVersion_Request)(nil), // 7: CIVersion.Request + (*CIVersion_Response)(nil), // 8: CIVersion.Response + (*RunCondition_Request)(nil), // 9: RunCondition.Request + (*RunCondition_Response)(nil), // 10: RunCondition.Response + nil, // 11: RunCondition.Request.ValueEntry + (*GetCurrentBranch_Request)(nil), // 12: GetCurrentBranch.Request + (*GetCurrentBranch_Response)(nil), // 13: GetCurrentBranch.Response + (*GetCurrentSHA_Request)(nil), // 14: GetCurrentSHA.Request + (*GetCurrentSHA_Response)(nil), // 15: GetCurrentSHA.Response } var file_pkg_condition_ci_condition_proto_depIdxs = []int32{ - 8, // 0: RunCondition.Request.value:type_name -> RunCondition.Request.ValueEntry - 4, // 1: CIConditionPlugin.Name:input_type -> CIName.Request - 6, // 2: CIConditionPlugin.RunCondition:input_type -> RunCondition.Request - 9, // 3: CIConditionPlugin.GetCurrentBranch:input_type -> GetCurrentBranch.Request - 11, // 4: CIConditionPlugin.GetCurrentSHA:input_type -> GetCurrentSHA.Request - 5, // 5: CIConditionPlugin.Name:output_type -> CIName.Response - 7, // 6: CIConditionPlugin.RunCondition:output_type -> RunCondition.Response - 10, // 7: CIConditionPlugin.GetCurrentBranch:output_type -> GetCurrentBranch.Response - 12, // 8: CIConditionPlugin.GetCurrentSHA:output_type -> GetCurrentSHA.Response - 5, // [5:9] is the sub-list for method output_type - 1, // [1:5] is the sub-list for method input_type + 11, // 0: RunCondition.Request.value:type_name -> RunCondition.Request.ValueEntry + 5, // 1: CIConditionPlugin.Name:input_type -> CIName.Request + 7, // 2: CIConditionPlugin.Version:input_type -> CIVersion.Request + 9, // 3: CIConditionPlugin.RunCondition:input_type -> RunCondition.Request + 12, // 4: CIConditionPlugin.GetCurrentBranch:input_type -> GetCurrentBranch.Request + 14, // 5: CIConditionPlugin.GetCurrentSHA:input_type -> GetCurrentSHA.Request + 6, // 6: CIConditionPlugin.Name:output_type -> CIName.Response + 8, // 7: CIConditionPlugin.Version:output_type -> CIVersion.Response + 10, // 8: CIConditionPlugin.RunCondition:output_type -> RunCondition.Response + 13, // 9: CIConditionPlugin.GetCurrentBranch:output_type -> GetCurrentBranch.Response + 15, // 10: CIConditionPlugin.GetCurrentSHA:output_type -> GetCurrentSHA.Response + 6, // [6:11] is the sub-list for method output_type + 1, // [1:6] is the sub-list for method input_type 1, // [1:1] is the sub-list for extension type_name 1, // [1:1] is the sub-list for extension extendee 0, // [0:1] is the sub-list for field type_name @@ -642,7 +777,7 @@ func file_pkg_condition_ci_condition_proto_init() { } } file_pkg_condition_ci_condition_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RunCondition); i { + switch v := v.(*CIVersion); i { case 0: return &v.state case 1: @@ -654,7 +789,7 @@ func file_pkg_condition_ci_condition_proto_init() { } } file_pkg_condition_ci_condition_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetCurrentBranch); i { + switch v := v.(*RunCondition); i { case 0: return &v.state case 1: @@ -666,7 +801,7 @@ func file_pkg_condition_ci_condition_proto_init() { } } file_pkg_condition_ci_condition_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetCurrentSHA); i { + switch v := v.(*GetCurrentBranch); i { case 0: return &v.state case 1: @@ -678,7 +813,7 @@ func file_pkg_condition_ci_condition_proto_init() { } } file_pkg_condition_ci_condition_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CIName_Request); i { + switch v := v.(*GetCurrentSHA); i { case 0: return &v.state case 1: @@ -690,7 +825,7 @@ func file_pkg_condition_ci_condition_proto_init() { } } file_pkg_condition_ci_condition_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CIName_Response); i { + switch v := v.(*CIName_Request); i { case 0: return &v.state case 1: @@ -702,7 +837,7 @@ func file_pkg_condition_ci_condition_proto_init() { } } file_pkg_condition_ci_condition_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RunCondition_Request); i { + switch v := v.(*CIName_Response); i { case 0: return &v.state case 1: @@ -714,7 +849,19 @@ func file_pkg_condition_ci_condition_proto_init() { } } file_pkg_condition_ci_condition_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RunCondition_Response); i { + switch v := v.(*CIVersion_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_condition_ci_condition_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CIVersion_Response); i { case 0: return &v.state case 1: @@ -726,7 +873,7 @@ func file_pkg_condition_ci_condition_proto_init() { } } file_pkg_condition_ci_condition_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetCurrentBranch_Request); i { + switch v := v.(*RunCondition_Request); i { case 0: return &v.state case 1: @@ -738,6 +885,30 @@ func file_pkg_condition_ci_condition_proto_init() { } } file_pkg_condition_ci_condition_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*RunCondition_Response); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_condition_ci_condition_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GetCurrentBranch_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_condition_ci_condition_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetCurrentBranch_Response); i { case 0: return &v.state @@ -749,7 +920,7 @@ func file_pkg_condition_ci_condition_proto_init() { return nil } } - file_pkg_condition_ci_condition_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { + file_pkg_condition_ci_condition_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetCurrentSHA_Request); i { case 0: return &v.state @@ -761,7 +932,7 @@ func file_pkg_condition_ci_condition_proto_init() { return nil } } - file_pkg_condition_ci_condition_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { + file_pkg_condition_ci_condition_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetCurrentSHA_Response); i { case 0: return &v.state @@ -780,7 +951,7 @@ func file_pkg_condition_ci_condition_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_pkg_condition_ci_condition_proto_rawDesc, NumEnums: 0, - NumMessages: 13, + NumMessages: 16, NumExtensions: 0, NumServices: 1, }, diff --git a/pkg/condition/ci_condition.proto b/pkg/condition/ci_condition.proto index b014dc007108e49e3b627b3a39f1b011ea4ce27d..7463fa7ec7fb0ce95fd3c66d80ef8a6c074419c2 100644 --- a/pkg/condition/ci_condition.proto +++ b/pkg/condition/ci_condition.proto @@ -4,7 +4,14 @@ option go_package = "github.com/go-semantic-release/semantic-release/v2/pkg/cond message CIName { message Request {} message Response { - string value = 1; + string name = 1; + } +} + +message CIVersion { + message Request {} + message Response { + string version = 1; } } @@ -34,6 +41,7 @@ message GetCurrentSHA { service CIConditionPlugin { rpc Name(CIName.Request) returns (CIName.Response); + rpc Version(CIVersion.Request) returns (CIVersion.Response); rpc RunCondition(RunCondition.Request) returns (RunCondition.Response); rpc GetCurrentBranch(GetCurrentBranch.Request) returns (GetCurrentBranch.Response); rpc GetCurrentSHA(GetCurrentSHA.Request) returns (GetCurrentSHA.Response); diff --git a/pkg/condition/ci_condition_grpc.pb.go b/pkg/condition/ci_condition_grpc.pb.go index 7a109aff81fa41e534188c64814c95635cc13561..be5e6c9b19a5f55678d3f69026dede217f85b48f 100644 --- a/pkg/condition/ci_condition_grpc.pb.go +++ b/pkg/condition/ci_condition_grpc.pb.go @@ -18,6 +18,7 @@ const _ = grpc.SupportPackageIsVersion6 // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. type CIConditionPluginClient interface { Name(ctx context.Context, in *CIName_Request, opts ...grpc.CallOption) (*CIName_Response, error) + Version(ctx context.Context, in *CIVersion_Request, opts ...grpc.CallOption) (*CIVersion_Response, error) RunCondition(ctx context.Context, in *RunCondition_Request, opts ...grpc.CallOption) (*RunCondition_Response, error) GetCurrentBranch(ctx context.Context, in *GetCurrentBranch_Request, opts ...grpc.CallOption) (*GetCurrentBranch_Response, error) GetCurrentSHA(ctx context.Context, in *GetCurrentSHA_Request, opts ...grpc.CallOption) (*GetCurrentSHA_Response, error) @@ -40,6 +41,15 @@ func (c *cIConditionPluginClient) Name(ctx context.Context, in *CIName_Request, return out, nil } +func (c *cIConditionPluginClient) Version(ctx context.Context, in *CIVersion_Request, opts ...grpc.CallOption) (*CIVersion_Response, error) { + out := new(CIVersion_Response) + err := c.cc.Invoke(ctx, "/CIConditionPlugin/Version", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *cIConditionPluginClient) RunCondition(ctx context.Context, in *RunCondition_Request, opts ...grpc.CallOption) (*RunCondition_Response, error) { out := new(RunCondition_Response) err := c.cc.Invoke(ctx, "/CIConditionPlugin/RunCondition", in, out, opts...) @@ -72,6 +82,7 @@ func (c *cIConditionPluginClient) GetCurrentSHA(ctx context.Context, in *GetCurr // for forward compatibility type CIConditionPluginServer interface { Name(context.Context, *CIName_Request) (*CIName_Response, error) + Version(context.Context, *CIVersion_Request) (*CIVersion_Response, error) RunCondition(context.Context, *RunCondition_Request) (*RunCondition_Response, error) GetCurrentBranch(context.Context, *GetCurrentBranch_Request) (*GetCurrentBranch_Response, error) GetCurrentSHA(context.Context, *GetCurrentSHA_Request) (*GetCurrentSHA_Response, error) @@ -85,6 +96,9 @@ type UnimplementedCIConditionPluginServer struct { func (*UnimplementedCIConditionPluginServer) Name(context.Context, *CIName_Request) (*CIName_Response, error) { return nil, status.Errorf(codes.Unimplemented, "method Name not implemented") } +func (*UnimplementedCIConditionPluginServer) Version(context.Context, *CIVersion_Request) (*CIVersion_Response, error) { + return nil, status.Errorf(codes.Unimplemented, "method Version not implemented") +} func (*UnimplementedCIConditionPluginServer) RunCondition(context.Context, *RunCondition_Request) (*RunCondition_Response, error) { return nil, status.Errorf(codes.Unimplemented, "method RunCondition not implemented") } @@ -118,6 +132,24 @@ func _CIConditionPlugin_Name_Handler(srv interface{}, ctx context.Context, dec f return interceptor(ctx, in, info, handler) } +func _CIConditionPlugin_Version_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(CIVersion_Request) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(CIConditionPluginServer).Version(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/CIConditionPlugin/Version", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(CIConditionPluginServer).Version(ctx, req.(*CIVersion_Request)) + } + return interceptor(ctx, in, info, handler) +} + func _CIConditionPlugin_RunCondition_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(RunCondition_Request) if err := dec(in); err != nil { @@ -180,6 +212,10 @@ var _CIConditionPlugin_serviceDesc = grpc.ServiceDesc{ MethodName: "Name", Handler: _CIConditionPlugin_Name_Handler, }, + { + MethodName: "Version", + Handler: _CIConditionPlugin_Version_Handler, + }, { MethodName: "RunCondition", Handler: _CIConditionPlugin_RunCondition_Handler, diff --git a/pkg/condition/ci_condition_wrapper.go b/pkg/condition/ci_condition_wrapper.go index 2dbb726828e0bdda56f6cfc8cb35930e7275263e..4d1b273918eadfc88a9fad8fc00bc9f2d347eebf 100644 --- a/pkg/condition/ci_condition_wrapper.go +++ b/pkg/condition/ci_condition_wrapper.go @@ -13,7 +13,11 @@ type CIConditionServer struct { } func (c *CIConditionServer) Name(ctx context.Context, request *CIName_Request) (*CIName_Response, error) { - return &CIName_Response{Value: c.Impl.Name()}, nil + return &CIName_Response{Name: c.Impl.Name()}, nil +} + +func (c *CIConditionServer) Version(ctx context.Context, request *CIVersion_Request) (*CIVersion_Response, error) { + return &CIVersion_Response{Version: c.Impl.Name()}, nil } func (c *CIConditionServer) RunCondition(ctx context.Context, request *RunCondition_Request) (*RunCondition_Response, error) { @@ -38,11 +42,19 @@ type CIConditionClient struct { } func (c *CIConditionClient) Name() string { - name, err := c.Impl.Name(context.Background(), &CIName_Request{}) + res, err := c.Impl.Name(context.Background(), &CIName_Request{}) + if err != nil { + panic(err) + } + return res.Name +} + +func (c *CIConditionClient) Version() string { + res, err := c.Impl.Version(context.Background(), &CIVersion_Request{}) if err != nil { panic(err) } - return name.Value + return res.Version } func (c *CIConditionClient) RunCondition(m map[string]string) error { diff --git a/pkg/generator/changelog_generator.go b/pkg/generator/changelog_generator.go index f4e0f5addca7d5dfb59d7d0b298151bf985bf273..b2731ee7a46af7e4fe21052544df1ba4a14e9beb 100644 --- a/pkg/generator/changelog_generator.go +++ b/pkg/generator/changelog_generator.go @@ -1,5 +1,8 @@ package generator type ChangelogGenerator interface { + Init(map[string]string) error + Name() string + Version() string Generate(*ChangelogGeneratorConfig) string } diff --git a/pkg/generator/changelog_generator.pb.go b/pkg/generator/changelog_generator.pb.go index 5170354fd146a8f38de23929a07b2fc4a6b077c6..5c3ae11ef4c012513738ebeafd3b8b263d7a229d 100644 --- a/pkg/generator/changelog_generator.pb.go +++ b/pkg/generator/changelog_generator.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.25.0 -// protoc v3.12.3 +// protoc-gen-go v1.23.0 +// protoc v3.12.4 // source: pkg/generator/changelog_generator.proto package generator @@ -26,6 +26,120 @@ const ( // of the legacy proto package is being used. const _ = proto.ProtoPackageIsVersion4 +type ChangelogGeneratorInit struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *ChangelogGeneratorInit) Reset() { + *x = ChangelogGeneratorInit{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ChangelogGeneratorInit) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ChangelogGeneratorInit) ProtoMessage() {} + +func (x *ChangelogGeneratorInit) ProtoReflect() protoreflect.Message { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ChangelogGeneratorInit.ProtoReflect.Descriptor instead. +func (*ChangelogGeneratorInit) Descriptor() ([]byte, []int) { + return file_pkg_generator_changelog_generator_proto_rawDescGZIP(), []int{0} +} + +type ChangelogGeneratorName struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *ChangelogGeneratorName) Reset() { + *x = ChangelogGeneratorName{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ChangelogGeneratorName) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ChangelogGeneratorName) ProtoMessage() {} + +func (x *ChangelogGeneratorName) ProtoReflect() protoreflect.Message { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ChangelogGeneratorName.ProtoReflect.Descriptor instead. +func (*ChangelogGeneratorName) Descriptor() ([]byte, []int) { + return file_pkg_generator_changelog_generator_proto_rawDescGZIP(), []int{1} +} + +type ChangelogGeneratorVersion struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *ChangelogGeneratorVersion) Reset() { + *x = ChangelogGeneratorVersion{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ChangelogGeneratorVersion) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ChangelogGeneratorVersion) ProtoMessage() {} + +func (x *ChangelogGeneratorVersion) ProtoReflect() protoreflect.Message { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ChangelogGeneratorVersion.ProtoReflect.Descriptor instead. +func (*ChangelogGeneratorVersion) Descriptor() ([]byte, []int) { + return file_pkg_generator_changelog_generator_proto_rawDescGZIP(), []int{2} +} + type ChangelogGeneratorConfig struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -39,7 +153,7 @@ type ChangelogGeneratorConfig struct { func (x *ChangelogGeneratorConfig) Reset() { *x = ChangelogGeneratorConfig{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_generator_changelog_generator_proto_msgTypes[0] + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -52,7 +166,7 @@ func (x *ChangelogGeneratorConfig) String() string { func (*ChangelogGeneratorConfig) ProtoMessage() {} func (x *ChangelogGeneratorConfig) ProtoReflect() protoreflect.Message { - mi := &file_pkg_generator_changelog_generator_proto_msgTypes[0] + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[3] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -65,7 +179,7 @@ func (x *ChangelogGeneratorConfig) ProtoReflect() protoreflect.Message { // Deprecated: Use ChangelogGeneratorConfig.ProtoReflect.Descriptor instead. func (*ChangelogGeneratorConfig) Descriptor() ([]byte, []int) { - return file_pkg_generator_changelog_generator_proto_rawDescGZIP(), []int{0} + return file_pkg_generator_changelog_generator_proto_rawDescGZIP(), []int{3} } func (x *ChangelogGeneratorConfig) GetCommits() []*semrel.Commit { @@ -98,7 +212,7 @@ type GenerateChangelog struct { func (x *GenerateChangelog) Reset() { *x = GenerateChangelog{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_generator_changelog_generator_proto_msgTypes[1] + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -111,7 +225,7 @@ func (x *GenerateChangelog) String() string { func (*GenerateChangelog) ProtoMessage() {} func (x *GenerateChangelog) ProtoReflect() protoreflect.Message { - mi := &file_pkg_generator_changelog_generator_proto_msgTypes[1] + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[4] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -124,7 +238,271 @@ func (x *GenerateChangelog) ProtoReflect() protoreflect.Message { // Deprecated: Use GenerateChangelog.ProtoReflect.Descriptor instead. func (*GenerateChangelog) Descriptor() ([]byte, []int) { - return file_pkg_generator_changelog_generator_proto_rawDescGZIP(), []int{1} + return file_pkg_generator_changelog_generator_proto_rawDescGZIP(), []int{4} +} + +type ChangelogGeneratorInit_Request struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Config map[string]string `protobuf:"bytes,1,rep,name=config,proto3" json:"config,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` +} + +func (x *ChangelogGeneratorInit_Request) Reset() { + *x = ChangelogGeneratorInit_Request{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ChangelogGeneratorInit_Request) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ChangelogGeneratorInit_Request) ProtoMessage() {} + +func (x *ChangelogGeneratorInit_Request) ProtoReflect() protoreflect.Message { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ChangelogGeneratorInit_Request.ProtoReflect.Descriptor instead. +func (*ChangelogGeneratorInit_Request) Descriptor() ([]byte, []int) { + return file_pkg_generator_changelog_generator_proto_rawDescGZIP(), []int{0, 0} +} + +func (x *ChangelogGeneratorInit_Request) GetConfig() map[string]string { + if x != nil { + return x.Config + } + return nil +} + +type ChangelogGeneratorInit_Response struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Error string `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"` +} + +func (x *ChangelogGeneratorInit_Response) Reset() { + *x = ChangelogGeneratorInit_Response{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ChangelogGeneratorInit_Response) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ChangelogGeneratorInit_Response) ProtoMessage() {} + +func (x *ChangelogGeneratorInit_Response) ProtoReflect() protoreflect.Message { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[6] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ChangelogGeneratorInit_Response.ProtoReflect.Descriptor instead. +func (*ChangelogGeneratorInit_Response) Descriptor() ([]byte, []int) { + return file_pkg_generator_changelog_generator_proto_rawDescGZIP(), []int{0, 1} +} + +func (x *ChangelogGeneratorInit_Response) GetError() string { + if x != nil { + return x.Error + } + return "" +} + +type ChangelogGeneratorName_Request struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *ChangelogGeneratorName_Request) Reset() { + *x = ChangelogGeneratorName_Request{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ChangelogGeneratorName_Request) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ChangelogGeneratorName_Request) ProtoMessage() {} + +func (x *ChangelogGeneratorName_Request) ProtoReflect() protoreflect.Message { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[8] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ChangelogGeneratorName_Request.ProtoReflect.Descriptor instead. +func (*ChangelogGeneratorName_Request) Descriptor() ([]byte, []int) { + return file_pkg_generator_changelog_generator_proto_rawDescGZIP(), []int{1, 0} +} + +type ChangelogGeneratorName_Response struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` +} + +func (x *ChangelogGeneratorName_Response) Reset() { + *x = ChangelogGeneratorName_Response{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ChangelogGeneratorName_Response) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ChangelogGeneratorName_Response) ProtoMessage() {} + +func (x *ChangelogGeneratorName_Response) ProtoReflect() protoreflect.Message { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[9] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ChangelogGeneratorName_Response.ProtoReflect.Descriptor instead. +func (*ChangelogGeneratorName_Response) Descriptor() ([]byte, []int) { + return file_pkg_generator_changelog_generator_proto_rawDescGZIP(), []int{1, 1} +} + +func (x *ChangelogGeneratorName_Response) GetName() string { + if x != nil { + return x.Name + } + return "" +} + +type ChangelogGeneratorVersion_Request struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *ChangelogGeneratorVersion_Request) Reset() { + *x = ChangelogGeneratorVersion_Request{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ChangelogGeneratorVersion_Request) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ChangelogGeneratorVersion_Request) ProtoMessage() {} + +func (x *ChangelogGeneratorVersion_Request) ProtoReflect() protoreflect.Message { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[10] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ChangelogGeneratorVersion_Request.ProtoReflect.Descriptor instead. +func (*ChangelogGeneratorVersion_Request) Descriptor() ([]byte, []int) { + return file_pkg_generator_changelog_generator_proto_rawDescGZIP(), []int{2, 0} +} + +type ChangelogGeneratorVersion_Response struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"` +} + +func (x *ChangelogGeneratorVersion_Response) Reset() { + *x = ChangelogGeneratorVersion_Response{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ChangelogGeneratorVersion_Response) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ChangelogGeneratorVersion_Response) ProtoMessage() {} + +func (x *ChangelogGeneratorVersion_Response) ProtoReflect() protoreflect.Message { + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[11] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ChangelogGeneratorVersion_Response.ProtoReflect.Descriptor instead. +func (*ChangelogGeneratorVersion_Response) Descriptor() ([]byte, []int) { + return file_pkg_generator_changelog_generator_proto_rawDescGZIP(), []int{2, 1} +} + +func (x *ChangelogGeneratorVersion_Response) GetVersion() string { + if x != nil { + return x.Version + } + return "" } type GenerateChangelog_Request struct { @@ -138,7 +516,7 @@ type GenerateChangelog_Request struct { func (x *GenerateChangelog_Request) Reset() { *x = GenerateChangelog_Request{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_generator_changelog_generator_proto_msgTypes[2] + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -151,7 +529,7 @@ func (x *GenerateChangelog_Request) String() string { func (*GenerateChangelog_Request) ProtoMessage() {} func (x *GenerateChangelog_Request) ProtoReflect() protoreflect.Message { - mi := &file_pkg_generator_changelog_generator_proto_msgTypes[2] + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -164,7 +542,7 @@ func (x *GenerateChangelog_Request) ProtoReflect() protoreflect.Message { // Deprecated: Use GenerateChangelog_Request.ProtoReflect.Descriptor instead. func (*GenerateChangelog_Request) Descriptor() ([]byte, []int) { - return file_pkg_generator_changelog_generator_proto_rawDescGZIP(), []int{1, 0} + return file_pkg_generator_changelog_generator_proto_rawDescGZIP(), []int{4, 0} } func (x *GenerateChangelog_Request) GetConfig() *ChangelogGeneratorConfig { @@ -185,7 +563,7 @@ type GenerateChangelog_Response struct { func (x *GenerateChangelog_Response) Reset() { *x = GenerateChangelog_Response{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_generator_changelog_generator_proto_msgTypes[3] + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -198,7 +576,7 @@ func (x *GenerateChangelog_Response) String() string { func (*GenerateChangelog_Response) ProtoMessage() {} func (x *GenerateChangelog_Response) ProtoReflect() protoreflect.Message { - mi := &file_pkg_generator_changelog_generator_proto_msgTypes[3] + mi := &file_pkg_generator_changelog_generator_proto_msgTypes[13] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -211,7 +589,7 @@ func (x *GenerateChangelog_Response) ProtoReflect() protoreflect.Message { // Deprecated: Use GenerateChangelog_Response.ProtoReflect.Descriptor instead. func (*GenerateChangelog_Response) Descriptor() ([]byte, []int) { - return file_pkg_generator_changelog_generator_proto_rawDescGZIP(), []int{1, 1} + return file_pkg_generator_changelog_generator_proto_rawDescGZIP(), []int{4, 1} } func (x *GenerateChangelog_Response) GetChangelog() string { @@ -228,34 +606,71 @@ var file_pkg_generator_changelog_generator_proto_rawDesc = []byte{ 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x5f, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x18, 0x70, 0x6b, 0x67, 0x2f, 0x73, 0x65, 0x6d, 0x72, 0x65, 0x6c, 0x2f, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x73, 0x2e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x22, 0x8f, 0x01, 0x0a, 0x18, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, - 0x67, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, - 0x12, 0x21, 0x0a, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, - 0x0b, 0x32, 0x07, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x07, 0x63, 0x6f, 0x6d, 0x6d, - 0x69, 0x74, 0x73, 0x12, 0x2f, 0x0a, 0x0e, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x5f, 0x72, 0x65, - 0x6c, 0x65, 0x61, 0x73, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x08, 0x2e, 0x52, 0x65, - 0x6c, 0x65, 0x61, 0x73, 0x65, 0x52, 0x0d, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x6c, - 0x65, 0x61, 0x73, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x6e, 0x65, 0x77, 0x5f, 0x76, 0x65, 0x72, 0x73, - 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6e, 0x65, 0x77, 0x56, 0x65, - 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x22, 0x7b, 0x0a, 0x11, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, - 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x1a, 0x3c, 0x0a, 0x07, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x31, 0x0a, 0x06, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, - 0x67, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, - 0x52, 0x06, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x1a, 0x28, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, - 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, - 0x6f, 0x67, 0x32, 0x5f, 0x0a, 0x18, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x47, - 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x12, 0x43, - 0x0a, 0x08, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, 0x12, 0x1a, 0x2e, 0x47, 0x65, 0x6e, - 0x65, 0x72, 0x61, 0x74, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x2e, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1b, 0x2e, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, - 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x42, 0x42, 0x5a, 0x40, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, - 0x6d, 0x2f, 0x67, 0x6f, 0x2d, 0x73, 0x65, 0x6d, 0x61, 0x6e, 0x74, 0x69, 0x63, 0x2d, 0x72, 0x65, - 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2f, 0x73, 0x65, 0x6d, 0x61, 0x6e, 0x74, 0x69, 0x63, 0x2d, 0x72, - 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2f, 0x76, 0x32, 0x2f, 0x70, 0x6b, 0x67, 0x2f, 0x67, 0x65, - 0x6e, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x6f, 0x74, 0x6f, 0x22, 0xc6, 0x01, 0x0a, 0x16, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, + 0x67, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x49, 0x6e, 0x69, 0x74, 0x1a, 0x89, + 0x01, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x43, 0x0a, 0x06, 0x63, 0x6f, + 0x6e, 0x66, 0x69, 0x67, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2b, 0x2e, 0x43, 0x68, 0x61, + 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x49, + 0x6e, 0x69, 0x74, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x2e, 0x43, 0x6f, 0x6e, 0x66, + 0x69, 0x67, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x06, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x1a, + 0x39, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, + 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, + 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x20, 0x0a, 0x08, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x22, 0x43, 0x0a, 0x16, + 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, + 0x6f, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x1a, 0x09, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x1e, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, + 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, + 0x65, 0x22, 0x4c, 0x0a, 0x19, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x47, 0x65, + 0x6e, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x1a, 0x09, + 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x24, 0x0a, 0x08, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x22, + 0x8f, 0x01, 0x0a, 0x18, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x47, 0x65, 0x6e, + 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x21, 0x0a, 0x07, + 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x07, 0x2e, + 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x07, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x12, + 0x2f, 0x0a, 0x0e, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x5f, 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, + 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x08, 0x2e, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, + 0x65, 0x52, 0x0d, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, + 0x12, 0x1f, 0x0a, 0x0b, 0x6e, 0x65, 0x77, 0x5f, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6e, 0x65, 0x77, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, + 0x6e, 0x22, 0x7b, 0x0a, 0x11, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, 0x43, 0x68, 0x61, + 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x1a, 0x3c, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x31, 0x0a, 0x06, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x19, 0x2e, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x47, 0x65, 0x6e, + 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x06, 0x63, 0x6f, + 0x6e, 0x66, 0x69, 0x67, 0x1a, 0x28, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x1c, 0x0a, 0x09, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x09, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x32, 0xc9, + 0x02, 0x0a, 0x18, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x47, 0x65, 0x6e, 0x65, + 0x72, 0x61, 0x74, 0x6f, 0x72, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x12, 0x49, 0x0a, 0x04, 0x49, + 0x6e, 0x69, 0x74, 0x12, 0x1f, 0x2e, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x47, + 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x49, 0x6e, 0x69, 0x74, 0x2e, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, + 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x49, 0x6e, 0x69, 0x74, 0x2e, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x49, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1f, + 0x2e, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, + 0x74, 0x6f, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x20, 0x2e, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x47, 0x65, 0x6e, 0x65, 0x72, + 0x61, 0x74, 0x6f, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x12, 0x52, 0x0a, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x22, 0x2e, 0x43, + 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x6f, + 0x72, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x23, 0x2e, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x47, 0x65, 0x6e, 0x65, + 0x72, 0x61, 0x74, 0x6f, 0x72, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x43, 0x0a, 0x08, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, + 0x65, 0x12, 0x1a, 0x2e, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, 0x43, 0x68, 0x61, 0x6e, + 0x67, 0x65, 0x6c, 0x6f, 0x67, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1b, 0x2e, + 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x6c, 0x6f, + 0x67, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x42, 0x5a, 0x40, 0x67, 0x69, + 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x6f, 0x2d, 0x73, 0x65, 0x6d, 0x61, + 0x6e, 0x74, 0x69, 0x63, 0x2d, 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2f, 0x73, 0x65, 0x6d, + 0x61, 0x6e, 0x74, 0x69, 0x63, 0x2d, 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2f, 0x76, 0x32, + 0x2f, 0x70, 0x6b, 0x67, 0x2f, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x62, 0x06, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -270,26 +685,43 @@ func file_pkg_generator_changelog_generator_proto_rawDescGZIP() []byte { return file_pkg_generator_changelog_generator_proto_rawDescData } -var file_pkg_generator_changelog_generator_proto_msgTypes = make([]protoimpl.MessageInfo, 4) +var file_pkg_generator_changelog_generator_proto_msgTypes = make([]protoimpl.MessageInfo, 14) var file_pkg_generator_changelog_generator_proto_goTypes = []interface{}{ - (*ChangelogGeneratorConfig)(nil), // 0: ChangelogGeneratorConfig - (*GenerateChangelog)(nil), // 1: GenerateChangelog - (*GenerateChangelog_Request)(nil), // 2: GenerateChangelog.Request - (*GenerateChangelog_Response)(nil), // 3: GenerateChangelog.Response - (*semrel.Commit)(nil), // 4: Commit - (*semrel.Release)(nil), // 5: Release + (*ChangelogGeneratorInit)(nil), // 0: ChangelogGeneratorInit + (*ChangelogGeneratorName)(nil), // 1: ChangelogGeneratorName + (*ChangelogGeneratorVersion)(nil), // 2: ChangelogGeneratorVersion + (*ChangelogGeneratorConfig)(nil), // 3: ChangelogGeneratorConfig + (*GenerateChangelog)(nil), // 4: GenerateChangelog + (*ChangelogGeneratorInit_Request)(nil), // 5: ChangelogGeneratorInit.Request + (*ChangelogGeneratorInit_Response)(nil), // 6: ChangelogGeneratorInit.Response + nil, // 7: ChangelogGeneratorInit.Request.ConfigEntry + (*ChangelogGeneratorName_Request)(nil), // 8: ChangelogGeneratorName.Request + (*ChangelogGeneratorName_Response)(nil), // 9: ChangelogGeneratorName.Response + (*ChangelogGeneratorVersion_Request)(nil), // 10: ChangelogGeneratorVersion.Request + (*ChangelogGeneratorVersion_Response)(nil), // 11: ChangelogGeneratorVersion.Response + (*GenerateChangelog_Request)(nil), // 12: GenerateChangelog.Request + (*GenerateChangelog_Response)(nil), // 13: GenerateChangelog.Response + (*semrel.Commit)(nil), // 14: Commit + (*semrel.Release)(nil), // 15: Release } var file_pkg_generator_changelog_generator_proto_depIdxs = []int32{ - 4, // 0: ChangelogGeneratorConfig.commits:type_name -> Commit - 5, // 1: ChangelogGeneratorConfig.latest_release:type_name -> Release - 0, // 2: GenerateChangelog.Request.config:type_name -> ChangelogGeneratorConfig - 2, // 3: ChangelogGeneratorPlugin.Generate:input_type -> GenerateChangelog.Request - 3, // 4: ChangelogGeneratorPlugin.Generate:output_type -> GenerateChangelog.Response - 4, // [4:5] is the sub-list for method output_type - 3, // [3:4] is the sub-list for method input_type - 3, // [3:3] is the sub-list for extension type_name - 3, // [3:3] is the sub-list for extension extendee - 0, // [0:3] is the sub-list for field type_name + 14, // 0: ChangelogGeneratorConfig.commits:type_name -> Commit + 15, // 1: ChangelogGeneratorConfig.latest_release:type_name -> Release + 7, // 2: ChangelogGeneratorInit.Request.config:type_name -> ChangelogGeneratorInit.Request.ConfigEntry + 3, // 3: GenerateChangelog.Request.config:type_name -> ChangelogGeneratorConfig + 5, // 4: ChangelogGeneratorPlugin.Init:input_type -> ChangelogGeneratorInit.Request + 8, // 5: ChangelogGeneratorPlugin.Name:input_type -> ChangelogGeneratorName.Request + 10, // 6: ChangelogGeneratorPlugin.Version:input_type -> ChangelogGeneratorVersion.Request + 12, // 7: ChangelogGeneratorPlugin.Generate:input_type -> GenerateChangelog.Request + 6, // 8: ChangelogGeneratorPlugin.Init:output_type -> ChangelogGeneratorInit.Response + 9, // 9: ChangelogGeneratorPlugin.Name:output_type -> ChangelogGeneratorName.Response + 11, // 10: ChangelogGeneratorPlugin.Version:output_type -> ChangelogGeneratorVersion.Response + 13, // 11: ChangelogGeneratorPlugin.Generate:output_type -> GenerateChangelog.Response + 8, // [8:12] is the sub-list for method output_type + 4, // [4:8] is the sub-list for method input_type + 4, // [4:4] is the sub-list for extension type_name + 4, // [4:4] is the sub-list for extension extendee + 0, // [0:4] is the sub-list for field type_name } func init() { file_pkg_generator_changelog_generator_proto_init() } @@ -299,7 +731,7 @@ func file_pkg_generator_changelog_generator_proto_init() { } if !protoimpl.UnsafeEnabled { file_pkg_generator_changelog_generator_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ChangelogGeneratorConfig); i { + switch v := v.(*ChangelogGeneratorInit); i { case 0: return &v.state case 1: @@ -311,7 +743,7 @@ func file_pkg_generator_changelog_generator_proto_init() { } } file_pkg_generator_changelog_generator_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GenerateChangelog); i { + switch v := v.(*ChangelogGeneratorName); i { case 0: return &v.state case 1: @@ -323,7 +755,7 @@ func file_pkg_generator_changelog_generator_proto_init() { } } file_pkg_generator_changelog_generator_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GenerateChangelog_Request); i { + switch v := v.(*ChangelogGeneratorVersion); i { case 0: return &v.state case 1: @@ -335,6 +767,114 @@ func file_pkg_generator_changelog_generator_proto_init() { } } file_pkg_generator_changelog_generator_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ChangelogGeneratorConfig); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_generator_changelog_generator_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GenerateChangelog); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_generator_changelog_generator_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ChangelogGeneratorInit_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_generator_changelog_generator_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ChangelogGeneratorInit_Response); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_generator_changelog_generator_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ChangelogGeneratorName_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_generator_changelog_generator_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ChangelogGeneratorName_Response); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_generator_changelog_generator_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ChangelogGeneratorVersion_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_generator_changelog_generator_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ChangelogGeneratorVersion_Response); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_generator_changelog_generator_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GenerateChangelog_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_generator_changelog_generator_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GenerateChangelog_Response); i { case 0: return &v.state @@ -353,7 +893,7 @@ func file_pkg_generator_changelog_generator_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_pkg_generator_changelog_generator_proto_rawDesc, NumEnums: 0, - NumMessages: 4, + NumMessages: 14, NumExtensions: 0, NumServices: 1, }, diff --git a/pkg/generator/changelog_generator.proto b/pkg/generator/changelog_generator.proto index 3cf6779b61d2e8bfae6a89c81c91704ee5d94706..5df94953e080c48b902ebe27d450f4013f124481 100644 --- a/pkg/generator/changelog_generator.proto +++ b/pkg/generator/changelog_generator.proto @@ -3,6 +3,29 @@ option go_package = "github.com/go-semantic-release/semantic-release/v2/pkg/gene import "pkg/semrel/structs.proto"; +message ChangelogGeneratorInit { + message Request { + map<string, string> config = 1; + } + message Response { + string error = 1; + } +} + +message ChangelogGeneratorName { + message Request {} + message Response { + string name = 1; + } +} + +message ChangelogGeneratorVersion { + message Request {} + message Response { + string version = 1; + } +} + message ChangelogGeneratorConfig { repeated Commit commits = 1; Release latest_release = 2; @@ -19,5 +42,8 @@ message GenerateChangelog { } service ChangelogGeneratorPlugin { + rpc Init(ChangelogGeneratorInit.Request) returns (ChangelogGeneratorInit.Response); + rpc Name(ChangelogGeneratorName.Request) returns (ChangelogGeneratorName.Response); + rpc Version(ChangelogGeneratorVersion.Request) returns (ChangelogGeneratorVersion.Response); rpc Generate(GenerateChangelog.Request) returns (GenerateChangelog.Response); } diff --git a/pkg/generator/changelog_generator_grpc.pb.go b/pkg/generator/changelog_generator_grpc.pb.go index d6ba3c58c4e918b58c48ccc16faf55587aa4c866..32ad2d4a82e3587b397d56e9c900dec4959d06d5 100644 --- a/pkg/generator/changelog_generator_grpc.pb.go +++ b/pkg/generator/changelog_generator_grpc.pb.go @@ -17,6 +17,9 @@ const _ = grpc.SupportPackageIsVersion6 // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. type ChangelogGeneratorPluginClient interface { + Init(ctx context.Context, in *ChangelogGeneratorInit_Request, opts ...grpc.CallOption) (*ChangelogGeneratorInit_Response, error) + Name(ctx context.Context, in *ChangelogGeneratorName_Request, opts ...grpc.CallOption) (*ChangelogGeneratorName_Response, error) + Version(ctx context.Context, in *ChangelogGeneratorVersion_Request, opts ...grpc.CallOption) (*ChangelogGeneratorVersion_Response, error) Generate(ctx context.Context, in *GenerateChangelog_Request, opts ...grpc.CallOption) (*GenerateChangelog_Response, error) } @@ -28,6 +31,33 @@ func NewChangelogGeneratorPluginClient(cc grpc.ClientConnInterface) ChangelogGen return &changelogGeneratorPluginClient{cc} } +func (c *changelogGeneratorPluginClient) Init(ctx context.Context, in *ChangelogGeneratorInit_Request, opts ...grpc.CallOption) (*ChangelogGeneratorInit_Response, error) { + out := new(ChangelogGeneratorInit_Response) + err := c.cc.Invoke(ctx, "/ChangelogGeneratorPlugin/Init", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *changelogGeneratorPluginClient) Name(ctx context.Context, in *ChangelogGeneratorName_Request, opts ...grpc.CallOption) (*ChangelogGeneratorName_Response, error) { + out := new(ChangelogGeneratorName_Response) + err := c.cc.Invoke(ctx, "/ChangelogGeneratorPlugin/Name", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *changelogGeneratorPluginClient) Version(ctx context.Context, in *ChangelogGeneratorVersion_Request, opts ...grpc.CallOption) (*ChangelogGeneratorVersion_Response, error) { + out := new(ChangelogGeneratorVersion_Response) + err := c.cc.Invoke(ctx, "/ChangelogGeneratorPlugin/Version", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *changelogGeneratorPluginClient) Generate(ctx context.Context, in *GenerateChangelog_Request, opts ...grpc.CallOption) (*GenerateChangelog_Response, error) { out := new(GenerateChangelog_Response) err := c.cc.Invoke(ctx, "/ChangelogGeneratorPlugin/Generate", in, out, opts...) @@ -41,6 +71,9 @@ func (c *changelogGeneratorPluginClient) Generate(ctx context.Context, in *Gener // All implementations must embed UnimplementedChangelogGeneratorPluginServer // for forward compatibility type ChangelogGeneratorPluginServer interface { + Init(context.Context, *ChangelogGeneratorInit_Request) (*ChangelogGeneratorInit_Response, error) + Name(context.Context, *ChangelogGeneratorName_Request) (*ChangelogGeneratorName_Response, error) + Version(context.Context, *ChangelogGeneratorVersion_Request) (*ChangelogGeneratorVersion_Response, error) Generate(context.Context, *GenerateChangelog_Request) (*GenerateChangelog_Response, error) mustEmbedUnimplementedChangelogGeneratorPluginServer() } @@ -49,6 +82,15 @@ type ChangelogGeneratorPluginServer interface { type UnimplementedChangelogGeneratorPluginServer struct { } +func (*UnimplementedChangelogGeneratorPluginServer) Init(context.Context, *ChangelogGeneratorInit_Request) (*ChangelogGeneratorInit_Response, error) { + return nil, status.Errorf(codes.Unimplemented, "method Init not implemented") +} +func (*UnimplementedChangelogGeneratorPluginServer) Name(context.Context, *ChangelogGeneratorName_Request) (*ChangelogGeneratorName_Response, error) { + return nil, status.Errorf(codes.Unimplemented, "method Name not implemented") +} +func (*UnimplementedChangelogGeneratorPluginServer) Version(context.Context, *ChangelogGeneratorVersion_Request) (*ChangelogGeneratorVersion_Response, error) { + return nil, status.Errorf(codes.Unimplemented, "method Version not implemented") +} func (*UnimplementedChangelogGeneratorPluginServer) Generate(context.Context, *GenerateChangelog_Request) (*GenerateChangelog_Response, error) { return nil, status.Errorf(codes.Unimplemented, "method Generate not implemented") } @@ -59,6 +101,60 @@ func RegisterChangelogGeneratorPluginServer(s *grpc.Server, srv ChangelogGenerat s.RegisterService(&_ChangelogGeneratorPlugin_serviceDesc, srv) } +func _ChangelogGeneratorPlugin_Init_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(ChangelogGeneratorInit_Request) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(ChangelogGeneratorPluginServer).Init(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/ChangelogGeneratorPlugin/Init", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(ChangelogGeneratorPluginServer).Init(ctx, req.(*ChangelogGeneratorInit_Request)) + } + return interceptor(ctx, in, info, handler) +} + +func _ChangelogGeneratorPlugin_Name_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(ChangelogGeneratorName_Request) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(ChangelogGeneratorPluginServer).Name(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/ChangelogGeneratorPlugin/Name", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(ChangelogGeneratorPluginServer).Name(ctx, req.(*ChangelogGeneratorName_Request)) + } + return interceptor(ctx, in, info, handler) +} + +func _ChangelogGeneratorPlugin_Version_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(ChangelogGeneratorVersion_Request) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(ChangelogGeneratorPluginServer).Version(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/ChangelogGeneratorPlugin/Version", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(ChangelogGeneratorPluginServer).Version(ctx, req.(*ChangelogGeneratorVersion_Request)) + } + return interceptor(ctx, in, info, handler) +} + func _ChangelogGeneratorPlugin_Generate_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(GenerateChangelog_Request) if err := dec(in); err != nil { @@ -81,6 +177,18 @@ var _ChangelogGeneratorPlugin_serviceDesc = grpc.ServiceDesc{ ServiceName: "ChangelogGeneratorPlugin", HandlerType: (*ChangelogGeneratorPluginServer)(nil), Methods: []grpc.MethodDesc{ + { + MethodName: "Init", + Handler: _ChangelogGeneratorPlugin_Init_Handler, + }, + { + MethodName: "Name", + Handler: _ChangelogGeneratorPlugin_Name_Handler, + }, + { + MethodName: "Version", + Handler: _ChangelogGeneratorPlugin_Version_Handler, + }, { MethodName: "Generate", Handler: _ChangelogGeneratorPlugin_Generate_Handler, diff --git a/pkg/generator/changelog_generator_wrapper.go b/pkg/generator/changelog_generator_wrapper.go index b160979c8d6e3fa4a78147c9e77d1342e5f662a8..424d5f4a2d96fbeda38612efabc78afad710e8c5 100644 --- a/pkg/generator/changelog_generator_wrapper.go +++ b/pkg/generator/changelog_generator_wrapper.go @@ -1,6 +1,9 @@ package generator -import "context" +import ( + "context" + "errors" +) const ChangelogGeneratorPluginName = "changelog_generator" @@ -9,6 +12,23 @@ type ChangelogGeneratorServer struct { UnimplementedChangelogGeneratorPluginServer } +func (c *ChangelogGeneratorServer) Init(ctx context.Context, request *ChangelogGeneratorInit_Request) (*ChangelogGeneratorInit_Response, error) { + err := c.Impl.Init(request.Config) + res := &ChangelogGeneratorInit_Response{} + if err != nil { + res.Error = err.Error() + } + return res, nil +} + +func (c *ChangelogGeneratorServer) Name(ctx context.Context, request *ChangelogGeneratorName_Request) (*ChangelogGeneratorName_Response, error) { + return &ChangelogGeneratorName_Response{Name: c.Impl.Name()}, nil +} + +func (c *ChangelogGeneratorServer) Version(ctx context.Context, request *ChangelogGeneratorVersion_Request) (*ChangelogGeneratorVersion_Response, error) { + return &ChangelogGeneratorVersion_Response{Version: c.Impl.Version()}, nil +} + func (c *ChangelogGeneratorServer) Generate(ctx context.Context, request *GenerateChangelog_Request) (*GenerateChangelog_Response, error) { return &GenerateChangelog_Response{ Changelog: c.Impl.Generate(request.Config), @@ -26,3 +46,32 @@ func (c *ChangelogGeneratorClient) Generate(config *ChangelogGeneratorConfig) st } return res.Changelog } + +func (c *ChangelogGeneratorClient) Init(m map[string]string) error { + res, err := c.Impl.Init(context.Background(), &ChangelogGeneratorInit_Request{ + Config: m, + }) + if err != nil { + return err + } + if res.Error != "" { + return errors.New(res.Error) + } + return nil +} + +func (c *ChangelogGeneratorClient) Name() string { + res, err := c.Impl.Name(context.Background(), &ChangelogGeneratorName_Request{}) + if err != nil { + panic(err) + } + return res.Name +} + +func (c *ChangelogGeneratorClient) Version() string { + res, err := c.Impl.Version(context.Background(), &ChangelogGeneratorVersion_Request{}) + if err != nil { + panic(err) + } + return res.Version +} diff --git a/pkg/provider/provider.go b/pkg/provider/provider.go index 92a7ab0fafab39dcf70f99891c4a2094544aa8ab..26477ad57d346ccf51c7e01375370159b3a08b5d 100644 --- a/pkg/provider/provider.go +++ b/pkg/provider/provider.go @@ -6,9 +6,10 @@ import ( type Provider interface { Init(map[string]string) error + Name() string + Version() string GetInfo() (*RepositoryInfo, error) GetCommits(sha string) ([]*semrel.RawCommit, error) GetReleases(re string) ([]*semrel.Release, error) CreateRelease(*CreateReleaseConfig) error - Name() string } diff --git a/pkg/provider/provider.pb.go b/pkg/provider/provider.pb.go index c7b3d79da258dbc60adff63006f64e891f8a61c9..ff6824acc2240e2b73cdb0d1a12b94620f585c0f 100644 --- a/pkg/provider/provider.pb.go +++ b/pkg/provider/provider.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.25.0 -// protoc v3.12.3 +// protoc-gen-go v1.23.0 +// protoc v3.12.4 // source: pkg/provider/provider.proto package provider @@ -252,6 +252,44 @@ func (*ProviderName) Descriptor() ([]byte, []int) { return file_pkg_provider_provider_proto_rawDescGZIP(), []int{3} } +type ProviderVersion struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *ProviderVersion) Reset() { + *x = ProviderVersion{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_provider_provider_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ProviderVersion) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ProviderVersion) ProtoMessage() {} + +func (x *ProviderVersion) ProtoReflect() protoreflect.Message { + mi := &file_pkg_provider_provider_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ProviderVersion.ProtoReflect.Descriptor instead. +func (*ProviderVersion) Descriptor() ([]byte, []int) { + return file_pkg_provider_provider_proto_rawDescGZIP(), []int{4} +} + type GetInfo struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -261,7 +299,7 @@ type GetInfo struct { func (x *GetInfo) Reset() { *x = GetInfo{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_provider_provider_proto_msgTypes[4] + mi := &file_pkg_provider_provider_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -274,7 +312,7 @@ func (x *GetInfo) String() string { func (*GetInfo) ProtoMessage() {} func (x *GetInfo) ProtoReflect() protoreflect.Message { - mi := &file_pkg_provider_provider_proto_msgTypes[4] + mi := &file_pkg_provider_provider_proto_msgTypes[5] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -287,7 +325,7 @@ func (x *GetInfo) ProtoReflect() protoreflect.Message { // Deprecated: Use GetInfo.ProtoReflect.Descriptor instead. func (*GetInfo) Descriptor() ([]byte, []int) { - return file_pkg_provider_provider_proto_rawDescGZIP(), []int{4} + return file_pkg_provider_provider_proto_rawDescGZIP(), []int{5} } type GetCommits struct { @@ -299,7 +337,7 @@ type GetCommits struct { func (x *GetCommits) Reset() { *x = GetCommits{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_provider_provider_proto_msgTypes[5] + mi := &file_pkg_provider_provider_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -312,7 +350,7 @@ func (x *GetCommits) String() string { func (*GetCommits) ProtoMessage() {} func (x *GetCommits) ProtoReflect() protoreflect.Message { - mi := &file_pkg_provider_provider_proto_msgTypes[5] + mi := &file_pkg_provider_provider_proto_msgTypes[6] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -325,7 +363,7 @@ func (x *GetCommits) ProtoReflect() protoreflect.Message { // Deprecated: Use GetCommits.ProtoReflect.Descriptor instead. func (*GetCommits) Descriptor() ([]byte, []int) { - return file_pkg_provider_provider_proto_rawDescGZIP(), []int{5} + return file_pkg_provider_provider_proto_rawDescGZIP(), []int{6} } type GetReleases struct { @@ -337,7 +375,7 @@ type GetReleases struct { func (x *GetReleases) Reset() { *x = GetReleases{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_provider_provider_proto_msgTypes[6] + mi := &file_pkg_provider_provider_proto_msgTypes[7] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -350,7 +388,7 @@ func (x *GetReleases) String() string { func (*GetReleases) ProtoMessage() {} func (x *GetReleases) ProtoReflect() protoreflect.Message { - mi := &file_pkg_provider_provider_proto_msgTypes[6] + mi := &file_pkg_provider_provider_proto_msgTypes[7] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -363,7 +401,7 @@ func (x *GetReleases) ProtoReflect() protoreflect.Message { // Deprecated: Use GetReleases.ProtoReflect.Descriptor instead. func (*GetReleases) Descriptor() ([]byte, []int) { - return file_pkg_provider_provider_proto_rawDescGZIP(), []int{6} + return file_pkg_provider_provider_proto_rawDescGZIP(), []int{7} } type CreateRelease struct { @@ -375,7 +413,7 @@ type CreateRelease struct { func (x *CreateRelease) Reset() { *x = CreateRelease{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_provider_provider_proto_msgTypes[7] + mi := &file_pkg_provider_provider_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -388,7 +426,7 @@ func (x *CreateRelease) String() string { func (*CreateRelease) ProtoMessage() {} func (x *CreateRelease) ProtoReflect() protoreflect.Message { - mi := &file_pkg_provider_provider_proto_msgTypes[7] + mi := &file_pkg_provider_provider_proto_msgTypes[8] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -401,7 +439,7 @@ func (x *CreateRelease) ProtoReflect() protoreflect.Message { // Deprecated: Use CreateRelease.ProtoReflect.Descriptor instead. func (*CreateRelease) Descriptor() ([]byte, []int) { - return file_pkg_provider_provider_proto_rawDescGZIP(), []int{7} + return file_pkg_provider_provider_proto_rawDescGZIP(), []int{8} } type ProviderInit_Request struct { @@ -415,7 +453,7 @@ type ProviderInit_Request struct { func (x *ProviderInit_Request) Reset() { *x = ProviderInit_Request{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_provider_provider_proto_msgTypes[8] + mi := &file_pkg_provider_provider_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -428,7 +466,7 @@ func (x *ProviderInit_Request) String() string { func (*ProviderInit_Request) ProtoMessage() {} func (x *ProviderInit_Request) ProtoReflect() protoreflect.Message { - mi := &file_pkg_provider_provider_proto_msgTypes[8] + mi := &file_pkg_provider_provider_proto_msgTypes[9] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -462,7 +500,7 @@ type ProviderInit_Response struct { func (x *ProviderInit_Response) Reset() { *x = ProviderInit_Response{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_provider_provider_proto_msgTypes[9] + mi := &file_pkg_provider_provider_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -475,7 +513,7 @@ func (x *ProviderInit_Response) String() string { func (*ProviderInit_Response) ProtoMessage() {} func (x *ProviderInit_Response) ProtoReflect() protoreflect.Message { - mi := &file_pkg_provider_provider_proto_msgTypes[9] + mi := &file_pkg_provider_provider_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -507,7 +545,7 @@ type ProviderName_Request struct { func (x *ProviderName_Request) Reset() { *x = ProviderName_Request{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_provider_provider_proto_msgTypes[11] + mi := &file_pkg_provider_provider_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -520,7 +558,7 @@ func (x *ProviderName_Request) String() string { func (*ProviderName_Request) ProtoMessage() {} func (x *ProviderName_Request) ProtoReflect() protoreflect.Message { - mi := &file_pkg_provider_provider_proto_msgTypes[11] + mi := &file_pkg_provider_provider_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -547,7 +585,7 @@ type ProviderName_Response struct { func (x *ProviderName_Response) Reset() { *x = ProviderName_Response{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_provider_provider_proto_msgTypes[12] + mi := &file_pkg_provider_provider_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -560,7 +598,7 @@ func (x *ProviderName_Response) String() string { func (*ProviderName_Response) ProtoMessage() {} func (x *ProviderName_Response) ProtoReflect() protoreflect.Message { - mi := &file_pkg_provider_provider_proto_msgTypes[12] + mi := &file_pkg_provider_provider_proto_msgTypes[13] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -583,6 +621,91 @@ func (x *ProviderName_Response) GetName() string { return "" } +type ProviderVersion_Request struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *ProviderVersion_Request) Reset() { + *x = ProviderVersion_Request{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_provider_provider_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ProviderVersion_Request) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ProviderVersion_Request) ProtoMessage() {} + +func (x *ProviderVersion_Request) ProtoReflect() protoreflect.Message { + mi := &file_pkg_provider_provider_proto_msgTypes[14] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ProviderVersion_Request.ProtoReflect.Descriptor instead. +func (*ProviderVersion_Request) Descriptor() ([]byte, []int) { + return file_pkg_provider_provider_proto_rawDescGZIP(), []int{4, 0} +} + +type ProviderVersion_Response struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"` +} + +func (x *ProviderVersion_Response) Reset() { + *x = ProviderVersion_Response{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_provider_provider_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ProviderVersion_Response) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ProviderVersion_Response) ProtoMessage() {} + +func (x *ProviderVersion_Response) ProtoReflect() protoreflect.Message { + mi := &file_pkg_provider_provider_proto_msgTypes[15] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ProviderVersion_Response.ProtoReflect.Descriptor instead. +func (*ProviderVersion_Response) Descriptor() ([]byte, []int) { + return file_pkg_provider_provider_proto_rawDescGZIP(), []int{4, 1} +} + +func (x *ProviderVersion_Response) GetVersion() string { + if x != nil { + return x.Version + } + return "" +} + type GetInfo_Request struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -592,7 +715,7 @@ type GetInfo_Request struct { func (x *GetInfo_Request) Reset() { *x = GetInfo_Request{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_provider_provider_proto_msgTypes[13] + mi := &file_pkg_provider_provider_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -605,7 +728,7 @@ func (x *GetInfo_Request) String() string { func (*GetInfo_Request) ProtoMessage() {} func (x *GetInfo_Request) ProtoReflect() protoreflect.Message { - mi := &file_pkg_provider_provider_proto_msgTypes[13] + mi := &file_pkg_provider_provider_proto_msgTypes[16] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -618,7 +741,7 @@ func (x *GetInfo_Request) ProtoReflect() protoreflect.Message { // Deprecated: Use GetInfo_Request.ProtoReflect.Descriptor instead. func (*GetInfo_Request) Descriptor() ([]byte, []int) { - return file_pkg_provider_provider_proto_rawDescGZIP(), []int{4, 0} + return file_pkg_provider_provider_proto_rawDescGZIP(), []int{5, 0} } type GetInfo_Response struct { @@ -633,7 +756,7 @@ type GetInfo_Response struct { func (x *GetInfo_Response) Reset() { *x = GetInfo_Response{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_provider_provider_proto_msgTypes[14] + mi := &file_pkg_provider_provider_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -646,7 +769,7 @@ func (x *GetInfo_Response) String() string { func (*GetInfo_Response) ProtoMessage() {} func (x *GetInfo_Response) ProtoReflect() protoreflect.Message { - mi := &file_pkg_provider_provider_proto_msgTypes[14] + mi := &file_pkg_provider_provider_proto_msgTypes[17] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -659,7 +782,7 @@ func (x *GetInfo_Response) ProtoReflect() protoreflect.Message { // Deprecated: Use GetInfo_Response.ProtoReflect.Descriptor instead. func (*GetInfo_Response) Descriptor() ([]byte, []int) { - return file_pkg_provider_provider_proto_rawDescGZIP(), []int{4, 1} + return file_pkg_provider_provider_proto_rawDescGZIP(), []int{5, 1} } func (x *GetInfo_Response) GetInfo() *RepositoryInfo { @@ -687,7 +810,7 @@ type GetCommits_Request struct { func (x *GetCommits_Request) Reset() { *x = GetCommits_Request{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_provider_provider_proto_msgTypes[15] + mi := &file_pkg_provider_provider_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -700,7 +823,7 @@ func (x *GetCommits_Request) String() string { func (*GetCommits_Request) ProtoMessage() {} func (x *GetCommits_Request) ProtoReflect() protoreflect.Message { - mi := &file_pkg_provider_provider_proto_msgTypes[15] + mi := &file_pkg_provider_provider_proto_msgTypes[18] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -713,7 +836,7 @@ func (x *GetCommits_Request) ProtoReflect() protoreflect.Message { // Deprecated: Use GetCommits_Request.ProtoReflect.Descriptor instead. func (*GetCommits_Request) Descriptor() ([]byte, []int) { - return file_pkg_provider_provider_proto_rawDescGZIP(), []int{5, 0} + return file_pkg_provider_provider_proto_rawDescGZIP(), []int{6, 0} } func (x *GetCommits_Request) GetSHA() string { @@ -735,7 +858,7 @@ type GetCommits_Response struct { func (x *GetCommits_Response) Reset() { *x = GetCommits_Response{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_provider_provider_proto_msgTypes[16] + mi := &file_pkg_provider_provider_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -748,7 +871,7 @@ func (x *GetCommits_Response) String() string { func (*GetCommits_Response) ProtoMessage() {} func (x *GetCommits_Response) ProtoReflect() protoreflect.Message { - mi := &file_pkg_provider_provider_proto_msgTypes[16] + mi := &file_pkg_provider_provider_proto_msgTypes[19] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -761,7 +884,7 @@ func (x *GetCommits_Response) ProtoReflect() protoreflect.Message { // Deprecated: Use GetCommits_Response.ProtoReflect.Descriptor instead. func (*GetCommits_Response) Descriptor() ([]byte, []int) { - return file_pkg_provider_provider_proto_rawDescGZIP(), []int{5, 1} + return file_pkg_provider_provider_proto_rawDescGZIP(), []int{6, 1} } func (x *GetCommits_Response) GetRawCommits() []*semrel.RawCommit { @@ -789,7 +912,7 @@ type GetReleases_Request struct { func (x *GetReleases_Request) Reset() { *x = GetReleases_Request{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_provider_provider_proto_msgTypes[17] + mi := &file_pkg_provider_provider_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -802,7 +925,7 @@ func (x *GetReleases_Request) String() string { func (*GetReleases_Request) ProtoMessage() {} func (x *GetReleases_Request) ProtoReflect() protoreflect.Message { - mi := &file_pkg_provider_provider_proto_msgTypes[17] + mi := &file_pkg_provider_provider_proto_msgTypes[20] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -815,7 +938,7 @@ func (x *GetReleases_Request) ProtoReflect() protoreflect.Message { // Deprecated: Use GetReleases_Request.ProtoReflect.Descriptor instead. func (*GetReleases_Request) Descriptor() ([]byte, []int) { - return file_pkg_provider_provider_proto_rawDescGZIP(), []int{6, 0} + return file_pkg_provider_provider_proto_rawDescGZIP(), []int{7, 0} } func (x *GetReleases_Request) GetRegexp() string { @@ -837,7 +960,7 @@ type GetReleases_Response struct { func (x *GetReleases_Response) Reset() { *x = GetReleases_Response{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_provider_provider_proto_msgTypes[18] + mi := &file_pkg_provider_provider_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -850,7 +973,7 @@ func (x *GetReleases_Response) String() string { func (*GetReleases_Response) ProtoMessage() {} func (x *GetReleases_Response) ProtoReflect() protoreflect.Message { - mi := &file_pkg_provider_provider_proto_msgTypes[18] + mi := &file_pkg_provider_provider_proto_msgTypes[21] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -863,7 +986,7 @@ func (x *GetReleases_Response) ProtoReflect() protoreflect.Message { // Deprecated: Use GetReleases_Response.ProtoReflect.Descriptor instead. func (*GetReleases_Response) Descriptor() ([]byte, []int) { - return file_pkg_provider_provider_proto_rawDescGZIP(), []int{6, 1} + return file_pkg_provider_provider_proto_rawDescGZIP(), []int{7, 1} } func (x *GetReleases_Response) GetReleases() []*semrel.Release { @@ -891,7 +1014,7 @@ type CreateRelease_Request struct { func (x *CreateRelease_Request) Reset() { *x = CreateRelease_Request{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_provider_provider_proto_msgTypes[19] + mi := &file_pkg_provider_provider_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -904,7 +1027,7 @@ func (x *CreateRelease_Request) String() string { func (*CreateRelease_Request) ProtoMessage() {} func (x *CreateRelease_Request) ProtoReflect() protoreflect.Message { - mi := &file_pkg_provider_provider_proto_msgTypes[19] + mi := &file_pkg_provider_provider_proto_msgTypes[22] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -917,7 +1040,7 @@ func (x *CreateRelease_Request) ProtoReflect() protoreflect.Message { // Deprecated: Use CreateRelease_Request.ProtoReflect.Descriptor instead. func (*CreateRelease_Request) Descriptor() ([]byte, []int) { - return file_pkg_provider_provider_proto_rawDescGZIP(), []int{7, 0} + return file_pkg_provider_provider_proto_rawDescGZIP(), []int{8, 0} } func (x *CreateRelease_Request) GetConfig() *CreateReleaseConfig { @@ -938,7 +1061,7 @@ type CreateRelease_Response struct { func (x *CreateRelease_Response) Reset() { *x = CreateRelease_Response{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_provider_provider_proto_msgTypes[20] + mi := &file_pkg_provider_provider_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -951,7 +1074,7 @@ func (x *CreateRelease_Response) String() string { func (*CreateRelease_Response) ProtoMessage() {} func (x *CreateRelease_Response) ProtoReflect() protoreflect.Message { - mi := &file_pkg_provider_provider_proto_msgTypes[20] + mi := &file_pkg_provider_provider_proto_msgTypes[23] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -964,7 +1087,7 @@ func (x *CreateRelease_Response) ProtoReflect() protoreflect.Message { // Deprecated: Use CreateRelease_Response.ProtoReflect.Descriptor instead. func (*CreateRelease_Response) Descriptor() ([]byte, []int) { - return file_pkg_provider_provider_proto_rawDescGZIP(), []int{7, 1} + return file_pkg_provider_provider_proto_rawDescGZIP(), []int{8, 1} } func (x *CreateRelease_Response) GetError() string { @@ -1013,62 +1136,70 @@ var file_pkg_provider_provider_proto_rawDesc = []byte{ 0x76, 0x69, 0x64, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x1a, 0x09, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, - 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x5b, 0x0a, 0x07, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x1a, - 0x09, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x45, 0x0a, 0x08, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x23, 0x0a, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0f, 0x2e, 0x52, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x6f, 0x72, - 0x79, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x12, 0x14, 0x0a, 0x05, 0x65, - 0x72, 0x72, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, - 0x72, 0x22, 0x78, 0x0a, 0x0a, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x1a, - 0x1b, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x10, 0x0a, 0x03, 0x53, 0x48, - 0x41, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x53, 0x48, 0x41, 0x1a, 0x4d, 0x0a, 0x08, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2b, 0x0a, 0x0b, 0x72, 0x61, 0x77, 0x5f, - 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0a, 0x2e, - 0x52, 0x61, 0x77, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x0a, 0x72, 0x61, 0x77, 0x43, 0x6f, - 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x22, 0x78, 0x0a, 0x0b, 0x47, - 0x65, 0x74, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x73, 0x1a, 0x21, 0x0a, 0x07, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x67, 0x65, 0x78, 0x70, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x65, 0x67, 0x65, 0x78, 0x70, 0x1a, 0x46, 0x0a, - 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x24, 0x0a, 0x08, 0x72, 0x65, 0x6c, - 0x65, 0x61, 0x73, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x08, 0x2e, 0x52, 0x65, - 0x6c, 0x65, 0x61, 0x73, 0x65, 0x52, 0x08, 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x73, 0x12, + 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x42, 0x0a, 0x0f, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, + 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x1a, 0x09, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x24, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, + 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x22, 0x5b, 0x0a, 0x07, 0x47, 0x65, 0x74, 0x49, + 0x6e, 0x66, 0x6f, 0x1a, 0x09, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x45, + 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x23, 0x0a, 0x04, 0x69, 0x6e, + 0x66, 0x6f, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0f, 0x2e, 0x52, 0x65, 0x70, 0x6f, 0x73, + 0x69, 0x74, 0x6f, 0x72, 0x79, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, - 0x65, 0x72, 0x72, 0x6f, 0x72, 0x22, 0x6a, 0x0a, 0x0d, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, - 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x1a, 0x37, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x12, 0x2c, 0x0a, 0x06, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x14, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, - 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x06, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x1a, - 0x20, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x65, - 0x72, 0x72, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, - 0x72, 0x32, 0xe5, 0x02, 0x0a, 0x0e, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x50, 0x6c, - 0x75, 0x67, 0x69, 0x6e, 0x12, 0x35, 0x0a, 0x04, 0x49, 0x6e, 0x69, 0x74, 0x12, 0x15, 0x2e, 0x50, - 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x49, 0x6e, 0x69, 0x74, 0x2e, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x49, 0x6e, - 0x69, 0x74, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x35, 0x0a, 0x04, 0x4e, - 0x61, 0x6d, 0x65, 0x12, 0x15, 0x2e, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x4e, 0x61, - 0x6d, 0x65, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x50, 0x72, 0x6f, - 0x76, 0x69, 0x64, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x2e, 0x0a, 0x07, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x10, 0x2e, - 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x11, 0x2e, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x37, 0x0a, 0x0a, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, - 0x12, 0x13, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x2e, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x14, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x69, - 0x74, 0x73, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3a, 0x0a, 0x0b, 0x47, - 0x65, 0x74, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x73, 0x12, 0x14, 0x2e, 0x47, 0x65, 0x74, - 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x73, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x15, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x73, 0x2e, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x40, 0x0a, 0x0d, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x12, 0x16, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x17, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, - 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x41, 0x5a, 0x3f, 0x67, 0x69, 0x74, - 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x6f, 0x2d, 0x73, 0x65, 0x6d, 0x61, 0x6e, - 0x74, 0x69, 0x63, 0x2d, 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2f, 0x73, 0x65, 0x6d, 0x61, - 0x6e, 0x74, 0x69, 0x63, 0x2d, 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2f, 0x76, 0x32, 0x2f, - 0x70, 0x6b, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x62, 0x06, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x33, + 0x65, 0x72, 0x72, 0x6f, 0x72, 0x22, 0x78, 0x0a, 0x0a, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x73, 0x1a, 0x1b, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x10, + 0x0a, 0x03, 0x53, 0x48, 0x41, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x53, 0x48, 0x41, + 0x1a, 0x4d, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2b, 0x0a, 0x0b, + 0x72, 0x61, 0x77, 0x5f, 0x63, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, + 0x0b, 0x32, 0x0a, 0x2e, 0x52, 0x61, 0x77, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x0a, 0x72, + 0x61, 0x77, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x72, 0x72, + 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x22, + 0x78, 0x0a, 0x0b, 0x47, 0x65, 0x74, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x73, 0x1a, 0x21, + 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x67, + 0x65, 0x78, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x65, 0x67, 0x65, 0x78, + 0x70, 0x1a, 0x46, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x24, 0x0a, + 0x08, 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x08, 0x2e, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x52, 0x08, 0x72, 0x65, 0x6c, 0x65, 0x61, + 0x73, 0x65, 0x73, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x22, 0x6a, 0x0a, 0x0d, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x1a, 0x37, 0x0a, 0x07, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x2c, 0x0a, 0x06, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, + 0x6c, 0x65, 0x61, 0x73, 0x65, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x06, 0x63, 0x6f, 0x6e, + 0x66, 0x69, 0x67, 0x1a, 0x20, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x14, 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, + 0x65, 0x72, 0x72, 0x6f, 0x72, 0x32, 0xa5, 0x03, 0x0a, 0x0e, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, + 0x65, 0x72, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x12, 0x35, 0x0a, 0x04, 0x49, 0x6e, 0x69, 0x74, + 0x12, 0x15, 0x2e, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x49, 0x6e, 0x69, 0x74, 0x2e, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, + 0x65, 0x72, 0x49, 0x6e, 0x69, 0x74, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x35, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x15, 0x2e, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, + 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16, + 0x2e, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x2e, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3e, 0x0a, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, + 0x6e, 0x12, 0x18, 0x2e, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x56, 0x65, 0x72, 0x73, + 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x50, 0x72, + 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2e, 0x0a, 0x07, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, + 0x6f, 0x12, 0x10, 0x2e, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x2e, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x11, 0x2e, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x2e, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x37, 0x0a, 0x0a, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x73, 0x12, 0x13, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, + 0x73, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x14, 0x2e, 0x47, 0x65, 0x74, 0x43, + 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x73, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x3a, 0x0a, 0x0b, 0x47, 0x65, 0x74, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x73, 0x12, 0x14, + 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x73, 0x2e, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, + 0x65, 0x73, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x40, 0x0a, 0x0d, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x12, 0x16, 0x2e, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2e, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x17, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x6c, + 0x65, 0x61, 0x73, 0x65, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x41, 0x5a, + 0x3f, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x6f, 0x2d, 0x73, + 0x65, 0x6d, 0x61, 0x6e, 0x74, 0x69, 0x63, 0x2d, 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2f, + 0x73, 0x65, 0x6d, 0x61, 0x6e, 0x74, 0x69, 0x63, 0x2d, 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, + 0x2f, 0x76, 0x32, 0x2f, 0x70, 0x6b, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, + 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -1083,52 +1214,57 @@ func file_pkg_provider_provider_proto_rawDescGZIP() []byte { return file_pkg_provider_provider_proto_rawDescData } -var file_pkg_provider_provider_proto_msgTypes = make([]protoimpl.MessageInfo, 21) +var file_pkg_provider_provider_proto_msgTypes = make([]protoimpl.MessageInfo, 24) var file_pkg_provider_provider_proto_goTypes = []interface{}{ - (*RepositoryInfo)(nil), // 0: RepositoryInfo - (*CreateReleaseConfig)(nil), // 1: CreateReleaseConfig - (*ProviderInit)(nil), // 2: ProviderInit - (*ProviderName)(nil), // 3: ProviderName - (*GetInfo)(nil), // 4: GetInfo - (*GetCommits)(nil), // 5: GetCommits - (*GetReleases)(nil), // 6: GetReleases - (*CreateRelease)(nil), // 7: CreateRelease - (*ProviderInit_Request)(nil), // 8: ProviderInit.Request - (*ProviderInit_Response)(nil), // 9: ProviderInit.Response - nil, // 10: ProviderInit.Request.ConfigEntry - (*ProviderName_Request)(nil), // 11: ProviderName.Request - (*ProviderName_Response)(nil), // 12: ProviderName.Response - (*GetInfo_Request)(nil), // 13: GetInfo.Request - (*GetInfo_Response)(nil), // 14: GetInfo.Response - (*GetCommits_Request)(nil), // 15: GetCommits.Request - (*GetCommits_Response)(nil), // 16: GetCommits.Response - (*GetReleases_Request)(nil), // 17: GetReleases.Request - (*GetReleases_Response)(nil), // 18: GetReleases.Response - (*CreateRelease_Request)(nil), // 19: CreateRelease.Request - (*CreateRelease_Response)(nil), // 20: CreateRelease.Response - (*semrel.RawCommit)(nil), // 21: RawCommit - (*semrel.Release)(nil), // 22: Release + (*RepositoryInfo)(nil), // 0: RepositoryInfo + (*CreateReleaseConfig)(nil), // 1: CreateReleaseConfig + (*ProviderInit)(nil), // 2: ProviderInit + (*ProviderName)(nil), // 3: ProviderName + (*ProviderVersion)(nil), // 4: ProviderVersion + (*GetInfo)(nil), // 5: GetInfo + (*GetCommits)(nil), // 6: GetCommits + (*GetReleases)(nil), // 7: GetReleases + (*CreateRelease)(nil), // 8: CreateRelease + (*ProviderInit_Request)(nil), // 9: ProviderInit.Request + (*ProviderInit_Response)(nil), // 10: ProviderInit.Response + nil, // 11: ProviderInit.Request.ConfigEntry + (*ProviderName_Request)(nil), // 12: ProviderName.Request + (*ProviderName_Response)(nil), // 13: ProviderName.Response + (*ProviderVersion_Request)(nil), // 14: ProviderVersion.Request + (*ProviderVersion_Response)(nil), // 15: ProviderVersion.Response + (*GetInfo_Request)(nil), // 16: GetInfo.Request + (*GetInfo_Response)(nil), // 17: GetInfo.Response + (*GetCommits_Request)(nil), // 18: GetCommits.Request + (*GetCommits_Response)(nil), // 19: GetCommits.Response + (*GetReleases_Request)(nil), // 20: GetReleases.Request + (*GetReleases_Response)(nil), // 21: GetReleases.Response + (*CreateRelease_Request)(nil), // 22: CreateRelease.Request + (*CreateRelease_Response)(nil), // 23: CreateRelease.Response + (*semrel.RawCommit)(nil), // 24: RawCommit + (*semrel.Release)(nil), // 25: Release } var file_pkg_provider_provider_proto_depIdxs = []int32{ - 10, // 0: ProviderInit.Request.config:type_name -> ProviderInit.Request.ConfigEntry + 11, // 0: ProviderInit.Request.config:type_name -> ProviderInit.Request.ConfigEntry 0, // 1: GetInfo.Response.info:type_name -> RepositoryInfo - 21, // 2: GetCommits.Response.raw_commits:type_name -> RawCommit - 22, // 3: GetReleases.Response.releases:type_name -> Release + 24, // 2: GetCommits.Response.raw_commits:type_name -> RawCommit + 25, // 3: GetReleases.Response.releases:type_name -> Release 1, // 4: CreateRelease.Request.config:type_name -> CreateReleaseConfig - 8, // 5: ProviderPlugin.Init:input_type -> ProviderInit.Request - 11, // 6: ProviderPlugin.Name:input_type -> ProviderName.Request - 13, // 7: ProviderPlugin.GetInfo:input_type -> GetInfo.Request - 15, // 8: ProviderPlugin.GetCommits:input_type -> GetCommits.Request - 17, // 9: ProviderPlugin.GetReleases:input_type -> GetReleases.Request - 19, // 10: ProviderPlugin.CreateRelease:input_type -> CreateRelease.Request - 9, // 11: ProviderPlugin.Init:output_type -> ProviderInit.Response - 12, // 12: ProviderPlugin.Name:output_type -> ProviderName.Response - 14, // 13: ProviderPlugin.GetInfo:output_type -> GetInfo.Response - 16, // 14: ProviderPlugin.GetCommits:output_type -> GetCommits.Response - 18, // 15: ProviderPlugin.GetReleases:output_type -> GetReleases.Response - 20, // 16: ProviderPlugin.CreateRelease:output_type -> CreateRelease.Response - 11, // [11:17] is the sub-list for method output_type - 5, // [5:11] is the sub-list for method input_type + 9, // 5: ProviderPlugin.Init:input_type -> ProviderInit.Request + 12, // 6: ProviderPlugin.Name:input_type -> ProviderName.Request + 14, // 7: ProviderPlugin.Version:input_type -> ProviderVersion.Request + 16, // 8: ProviderPlugin.GetInfo:input_type -> GetInfo.Request + 18, // 9: ProviderPlugin.GetCommits:input_type -> GetCommits.Request + 20, // 10: ProviderPlugin.GetReleases:input_type -> GetReleases.Request + 22, // 11: ProviderPlugin.CreateRelease:input_type -> CreateRelease.Request + 10, // 12: ProviderPlugin.Init:output_type -> ProviderInit.Response + 13, // 13: ProviderPlugin.Name:output_type -> ProviderName.Response + 15, // 14: ProviderPlugin.Version:output_type -> ProviderVersion.Response + 17, // 15: ProviderPlugin.GetInfo:output_type -> GetInfo.Response + 19, // 16: ProviderPlugin.GetCommits:output_type -> GetCommits.Response + 21, // 17: ProviderPlugin.GetReleases:output_type -> GetReleases.Response + 23, // 18: ProviderPlugin.CreateRelease:output_type -> CreateRelease.Response + 12, // [12:19] is the sub-list for method output_type + 5, // [5:12] is the sub-list for method input_type 5, // [5:5] is the sub-list for extension type_name 5, // [5:5] is the sub-list for extension extendee 0, // [0:5] is the sub-list for field type_name @@ -1189,7 +1325,7 @@ func file_pkg_provider_provider_proto_init() { } } file_pkg_provider_provider_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetInfo); i { + switch v := v.(*ProviderVersion); i { case 0: return &v.state case 1: @@ -1201,7 +1337,7 @@ func file_pkg_provider_provider_proto_init() { } } file_pkg_provider_provider_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetCommits); i { + switch v := v.(*GetInfo); i { case 0: return &v.state case 1: @@ -1213,7 +1349,7 @@ func file_pkg_provider_provider_proto_init() { } } file_pkg_provider_provider_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetReleases); i { + switch v := v.(*GetCommits); i { case 0: return &v.state case 1: @@ -1225,7 +1361,7 @@ func file_pkg_provider_provider_proto_init() { } } file_pkg_provider_provider_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CreateRelease); i { + switch v := v.(*GetReleases); i { case 0: return &v.state case 1: @@ -1237,7 +1373,7 @@ func file_pkg_provider_provider_proto_init() { } } file_pkg_provider_provider_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ProviderInit_Request); i { + switch v := v.(*CreateRelease); i { case 0: return &v.state case 1: @@ -1249,6 +1385,18 @@ func file_pkg_provider_provider_proto_init() { } } file_pkg_provider_provider_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ProviderInit_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_provider_provider_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*ProviderInit_Response); i { case 0: return &v.state @@ -1260,7 +1408,7 @@ func file_pkg_provider_provider_proto_init() { return nil } } - file_pkg_provider_provider_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { + file_pkg_provider_provider_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*ProviderName_Request); i { case 0: return &v.state @@ -1272,7 +1420,7 @@ func file_pkg_provider_provider_proto_init() { return nil } } - file_pkg_provider_provider_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { + file_pkg_provider_provider_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*ProviderName_Response); i { case 0: return &v.state @@ -1284,7 +1432,31 @@ func file_pkg_provider_provider_proto_init() { return nil } } - file_pkg_provider_provider_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { + file_pkg_provider_provider_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ProviderVersion_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_provider_provider_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ProviderVersion_Response); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_provider_provider_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetInfo_Request); i { case 0: return &v.state @@ -1296,7 +1468,7 @@ func file_pkg_provider_provider_proto_init() { return nil } } - file_pkg_provider_provider_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { + file_pkg_provider_provider_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetInfo_Response); i { case 0: return &v.state @@ -1308,7 +1480,7 @@ func file_pkg_provider_provider_proto_init() { return nil } } - file_pkg_provider_provider_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { + file_pkg_provider_provider_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetCommits_Request); i { case 0: return &v.state @@ -1320,7 +1492,7 @@ func file_pkg_provider_provider_proto_init() { return nil } } - file_pkg_provider_provider_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { + file_pkg_provider_provider_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetCommits_Response); i { case 0: return &v.state @@ -1332,7 +1504,7 @@ func file_pkg_provider_provider_proto_init() { return nil } } - file_pkg_provider_provider_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { + file_pkg_provider_provider_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetReleases_Request); i { case 0: return &v.state @@ -1344,7 +1516,7 @@ func file_pkg_provider_provider_proto_init() { return nil } } - file_pkg_provider_provider_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { + file_pkg_provider_provider_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetReleases_Response); i { case 0: return &v.state @@ -1356,7 +1528,7 @@ func file_pkg_provider_provider_proto_init() { return nil } } - file_pkg_provider_provider_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { + file_pkg_provider_provider_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*CreateRelease_Request); i { case 0: return &v.state @@ -1368,7 +1540,7 @@ func file_pkg_provider_provider_proto_init() { return nil } } - file_pkg_provider_provider_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { + file_pkg_provider_provider_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*CreateRelease_Response); i { case 0: return &v.state @@ -1387,7 +1559,7 @@ func file_pkg_provider_provider_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_pkg_provider_provider_proto_rawDesc, NumEnums: 0, - NumMessages: 21, + NumMessages: 24, NumExtensions: 0, NumServices: 1, }, diff --git a/pkg/provider/provider.proto b/pkg/provider/provider.proto index c735b4d3c93f2afd76daf848cdd02d40d2ee4012..a13e5610f488d2acfbe0f772b2c1d8af40bedf6e 100644 --- a/pkg/provider/provider.proto +++ b/pkg/provider/provider.proto @@ -34,6 +34,13 @@ message ProviderName { } } +message ProviderVersion { + message Request {} + message Response { + string version = 1; + } +} + message GetInfo { message Request {} message Response { @@ -74,6 +81,7 @@ message CreateRelease { service ProviderPlugin { rpc Init(ProviderInit.Request) returns (ProviderInit.Response); rpc Name(ProviderName.Request) returns (ProviderName.Response); + rpc Version(ProviderVersion.Request) returns (ProviderVersion.Response); rpc GetInfo(GetInfo.Request) returns (GetInfo.Response); rpc GetCommits(GetCommits.Request) returns (GetCommits.Response); rpc GetReleases(GetReleases.Request) returns (GetReleases.Response); diff --git a/pkg/provider/provider_grpc.pb.go b/pkg/provider/provider_grpc.pb.go index 1f23f1bf8bffc54e6cab0f56401aa1091abdae3d..753012a32ac089ce78ec11adbd19b065b7f58a54 100644 --- a/pkg/provider/provider_grpc.pb.go +++ b/pkg/provider/provider_grpc.pb.go @@ -19,6 +19,7 @@ const _ = grpc.SupportPackageIsVersion6 type ProviderPluginClient interface { Init(ctx context.Context, in *ProviderInit_Request, opts ...grpc.CallOption) (*ProviderInit_Response, error) Name(ctx context.Context, in *ProviderName_Request, opts ...grpc.CallOption) (*ProviderName_Response, error) + Version(ctx context.Context, in *ProviderVersion_Request, opts ...grpc.CallOption) (*ProviderVersion_Response, error) GetInfo(ctx context.Context, in *GetInfo_Request, opts ...grpc.CallOption) (*GetInfo_Response, error) GetCommits(ctx context.Context, in *GetCommits_Request, opts ...grpc.CallOption) (*GetCommits_Response, error) GetReleases(ctx context.Context, in *GetReleases_Request, opts ...grpc.CallOption) (*GetReleases_Response, error) @@ -51,6 +52,15 @@ func (c *providerPluginClient) Name(ctx context.Context, in *ProviderName_Reques return out, nil } +func (c *providerPluginClient) Version(ctx context.Context, in *ProviderVersion_Request, opts ...grpc.CallOption) (*ProviderVersion_Response, error) { + out := new(ProviderVersion_Response) + err := c.cc.Invoke(ctx, "/ProviderPlugin/Version", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *providerPluginClient) GetInfo(ctx context.Context, in *GetInfo_Request, opts ...grpc.CallOption) (*GetInfo_Response, error) { out := new(GetInfo_Response) err := c.cc.Invoke(ctx, "/ProviderPlugin/GetInfo", in, out, opts...) @@ -93,6 +103,7 @@ func (c *providerPluginClient) CreateRelease(ctx context.Context, in *CreateRele type ProviderPluginServer interface { Init(context.Context, *ProviderInit_Request) (*ProviderInit_Response, error) Name(context.Context, *ProviderName_Request) (*ProviderName_Response, error) + Version(context.Context, *ProviderVersion_Request) (*ProviderVersion_Response, error) GetInfo(context.Context, *GetInfo_Request) (*GetInfo_Response, error) GetCommits(context.Context, *GetCommits_Request) (*GetCommits_Response, error) GetReleases(context.Context, *GetReleases_Request) (*GetReleases_Response, error) @@ -110,6 +121,9 @@ func (*UnimplementedProviderPluginServer) Init(context.Context, *ProviderInit_Re func (*UnimplementedProviderPluginServer) Name(context.Context, *ProviderName_Request) (*ProviderName_Response, error) { return nil, status.Errorf(codes.Unimplemented, "method Name not implemented") } +func (*UnimplementedProviderPluginServer) Version(context.Context, *ProviderVersion_Request) (*ProviderVersion_Response, error) { + return nil, status.Errorf(codes.Unimplemented, "method Version not implemented") +} func (*UnimplementedProviderPluginServer) GetInfo(context.Context, *GetInfo_Request) (*GetInfo_Response, error) { return nil, status.Errorf(codes.Unimplemented, "method GetInfo not implemented") } @@ -164,6 +178,24 @@ func _ProviderPlugin_Name_Handler(srv interface{}, ctx context.Context, dec func return interceptor(ctx, in, info, handler) } +func _ProviderPlugin_Version_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(ProviderVersion_Request) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(ProviderPluginServer).Version(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/ProviderPlugin/Version", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(ProviderPluginServer).Version(ctx, req.(*ProviderVersion_Request)) + } + return interceptor(ctx, in, info, handler) +} + func _ProviderPlugin_GetInfo_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(GetInfo_Request) if err := dec(in); err != nil { @@ -248,6 +280,10 @@ var _ProviderPlugin_serviceDesc = grpc.ServiceDesc{ MethodName: "Name", Handler: _ProviderPlugin_Name_Handler, }, + { + MethodName: "Version", + Handler: _ProviderPlugin_Version_Handler, + }, { MethodName: "GetInfo", Handler: _ProviderPlugin_GetInfo_Handler, diff --git a/pkg/provider/wrapper.go b/pkg/provider/wrapper.go index 24a99f558745acc1cdc3a8ae55000e50b58c5df2..40c46a2b3660af4600bda64b2a66dec57618408c 100644 --- a/pkg/provider/wrapper.go +++ b/pkg/provider/wrapper.go @@ -27,6 +27,10 @@ func (s *Server) Name(ctx context.Context, request *ProviderName_Request) (*Prov return &ProviderName_Response{Name: s.Impl.Name()}, nil } +func (s *Server) Version(ctx context.Context, request *ProviderVersion_Request) (*ProviderVersion_Response, error) { + return &ProviderVersion_Response{Version: s.Impl.Version()}, nil +} + func (s *Server) GetInfo(ctx context.Context, request *GetInfo_Request) (*GetInfo_Response, error) { info, err := s.Impl.GetInfo() if err != nil { @@ -134,3 +138,11 @@ func (c *Client) Name() string { } return res.Name } + +func (c *Client) Version() string { + res, err := c.Impl.Version(context.Background(), &ProviderVersion_Request{}) + if err != nil { + panic(err) + } + return res.Version +} diff --git a/pkg/semrel/structs.pb.go b/pkg/semrel/structs.pb.go index 38f173b3705cf6d3d98281b325940c93a9e5edfa..cc8deb4f2c019f226d055fd65514fe68b22c7919 100644 --- a/pkg/semrel/structs.pb.go +++ b/pkg/semrel/structs.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.25.0 -// protoc v3.12.3 +// protoc-gen-go v1.23.0 +// protoc v3.12.4 // source: pkg/semrel/structs.proto package semrel diff --git a/pkg/updater/updater.go b/pkg/updater/updater.go index ccccf0bdea4537d8372b313137fcc546fa78631a..b4f65520349f08cee5cc0a2a624e8cc80e909121 100644 --- a/pkg/updater/updater.go +++ b/pkg/updater/updater.go @@ -6,6 +6,9 @@ import ( ) type Updater interface { + Init(map[string]string) error + Name() string + Version() string Apply(file, newVersion string) error } diff --git a/pkg/updater/updater.pb.go b/pkg/updater/updater.pb.go index 5bb14f39310c932e55dd820d1820a842711ec74c..1e1bb32971790f5fe381e3d9c5e22ba5887f9e16 100644 --- a/pkg/updater/updater.pb.go +++ b/pkg/updater/updater.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.25.0 -// protoc v3.12.3 +// protoc-gen-go v1.23.0 +// protoc v3.12.4 // source: pkg/updater/updater.proto package updater @@ -25,6 +25,120 @@ const ( // of the legacy proto package is being used. const _ = proto.ProtoPackageIsVersion4 +type FilesUpdaterInit struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *FilesUpdaterInit) Reset() { + *x = FilesUpdaterInit{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_updater_updater_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *FilesUpdaterInit) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FilesUpdaterInit) ProtoMessage() {} + +func (x *FilesUpdaterInit) ProtoReflect() protoreflect.Message { + mi := &file_pkg_updater_updater_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use FilesUpdaterInit.ProtoReflect.Descriptor instead. +func (*FilesUpdaterInit) Descriptor() ([]byte, []int) { + return file_pkg_updater_updater_proto_rawDescGZIP(), []int{0} +} + +type FilesUpdaterName struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *FilesUpdaterName) Reset() { + *x = FilesUpdaterName{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_updater_updater_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *FilesUpdaterName) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FilesUpdaterName) ProtoMessage() {} + +func (x *FilesUpdaterName) ProtoReflect() protoreflect.Message { + mi := &file_pkg_updater_updater_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use FilesUpdaterName.ProtoReflect.Descriptor instead. +func (*FilesUpdaterName) Descriptor() ([]byte, []int) { + return file_pkg_updater_updater_proto_rawDescGZIP(), []int{1} +} + +type FilesUpdaterVersion struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *FilesUpdaterVersion) Reset() { + *x = FilesUpdaterVersion{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_updater_updater_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *FilesUpdaterVersion) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FilesUpdaterVersion) ProtoMessage() {} + +func (x *FilesUpdaterVersion) ProtoReflect() protoreflect.Message { + mi := &file_pkg_updater_updater_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use FilesUpdaterVersion.ProtoReflect.Descriptor instead. +func (*FilesUpdaterVersion) Descriptor() ([]byte, []int) { + return file_pkg_updater_updater_proto_rawDescGZIP(), []int{2} +} + type FilesUpdaterForFiles struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -34,7 +148,7 @@ type FilesUpdaterForFiles struct { func (x *FilesUpdaterForFiles) Reset() { *x = FilesUpdaterForFiles{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_updater_updater_proto_msgTypes[0] + mi := &file_pkg_updater_updater_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -47,7 +161,7 @@ func (x *FilesUpdaterForFiles) String() string { func (*FilesUpdaterForFiles) ProtoMessage() {} func (x *FilesUpdaterForFiles) ProtoReflect() protoreflect.Message { - mi := &file_pkg_updater_updater_proto_msgTypes[0] + mi := &file_pkg_updater_updater_proto_msgTypes[3] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -60,7 +174,7 @@ func (x *FilesUpdaterForFiles) ProtoReflect() protoreflect.Message { // Deprecated: Use FilesUpdaterForFiles.ProtoReflect.Descriptor instead. func (*FilesUpdaterForFiles) Descriptor() ([]byte, []int) { - return file_pkg_updater_updater_proto_rawDescGZIP(), []int{0} + return file_pkg_updater_updater_proto_rawDescGZIP(), []int{3} } type FilesUpdaterApply struct { @@ -72,7 +186,7 @@ type FilesUpdaterApply struct { func (x *FilesUpdaterApply) Reset() { *x = FilesUpdaterApply{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_updater_updater_proto_msgTypes[1] + mi := &file_pkg_updater_updater_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -85,7 +199,7 @@ func (x *FilesUpdaterApply) String() string { func (*FilesUpdaterApply) ProtoMessage() {} func (x *FilesUpdaterApply) ProtoReflect() protoreflect.Message { - mi := &file_pkg_updater_updater_proto_msgTypes[1] + mi := &file_pkg_updater_updater_proto_msgTypes[4] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -98,7 +212,271 @@ func (x *FilesUpdaterApply) ProtoReflect() protoreflect.Message { // Deprecated: Use FilesUpdaterApply.ProtoReflect.Descriptor instead. func (*FilesUpdaterApply) Descriptor() ([]byte, []int) { - return file_pkg_updater_updater_proto_rawDescGZIP(), []int{1} + return file_pkg_updater_updater_proto_rawDescGZIP(), []int{4} +} + +type FilesUpdaterInit_Request struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Config map[string]string `protobuf:"bytes,1,rep,name=config,proto3" json:"config,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` +} + +func (x *FilesUpdaterInit_Request) Reset() { + *x = FilesUpdaterInit_Request{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_updater_updater_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *FilesUpdaterInit_Request) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FilesUpdaterInit_Request) ProtoMessage() {} + +func (x *FilesUpdaterInit_Request) ProtoReflect() protoreflect.Message { + mi := &file_pkg_updater_updater_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use FilesUpdaterInit_Request.ProtoReflect.Descriptor instead. +func (*FilesUpdaterInit_Request) Descriptor() ([]byte, []int) { + return file_pkg_updater_updater_proto_rawDescGZIP(), []int{0, 0} +} + +func (x *FilesUpdaterInit_Request) GetConfig() map[string]string { + if x != nil { + return x.Config + } + return nil +} + +type FilesUpdaterInit_Response struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Error string `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"` +} + +func (x *FilesUpdaterInit_Response) Reset() { + *x = FilesUpdaterInit_Response{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_updater_updater_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *FilesUpdaterInit_Response) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FilesUpdaterInit_Response) ProtoMessage() {} + +func (x *FilesUpdaterInit_Response) ProtoReflect() protoreflect.Message { + mi := &file_pkg_updater_updater_proto_msgTypes[6] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use FilesUpdaterInit_Response.ProtoReflect.Descriptor instead. +func (*FilesUpdaterInit_Response) Descriptor() ([]byte, []int) { + return file_pkg_updater_updater_proto_rawDescGZIP(), []int{0, 1} +} + +func (x *FilesUpdaterInit_Response) GetError() string { + if x != nil { + return x.Error + } + return "" +} + +type FilesUpdaterName_Request struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *FilesUpdaterName_Request) Reset() { + *x = FilesUpdaterName_Request{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_updater_updater_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *FilesUpdaterName_Request) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FilesUpdaterName_Request) ProtoMessage() {} + +func (x *FilesUpdaterName_Request) ProtoReflect() protoreflect.Message { + mi := &file_pkg_updater_updater_proto_msgTypes[8] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use FilesUpdaterName_Request.ProtoReflect.Descriptor instead. +func (*FilesUpdaterName_Request) Descriptor() ([]byte, []int) { + return file_pkg_updater_updater_proto_rawDescGZIP(), []int{1, 0} +} + +type FilesUpdaterName_Response struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` +} + +func (x *FilesUpdaterName_Response) Reset() { + *x = FilesUpdaterName_Response{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_updater_updater_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *FilesUpdaterName_Response) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FilesUpdaterName_Response) ProtoMessage() {} + +func (x *FilesUpdaterName_Response) ProtoReflect() protoreflect.Message { + mi := &file_pkg_updater_updater_proto_msgTypes[9] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use FilesUpdaterName_Response.ProtoReflect.Descriptor instead. +func (*FilesUpdaterName_Response) Descriptor() ([]byte, []int) { + return file_pkg_updater_updater_proto_rawDescGZIP(), []int{1, 1} +} + +func (x *FilesUpdaterName_Response) GetName() string { + if x != nil { + return x.Name + } + return "" +} + +type FilesUpdaterVersion_Request struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *FilesUpdaterVersion_Request) Reset() { + *x = FilesUpdaterVersion_Request{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_updater_updater_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *FilesUpdaterVersion_Request) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FilesUpdaterVersion_Request) ProtoMessage() {} + +func (x *FilesUpdaterVersion_Request) ProtoReflect() protoreflect.Message { + mi := &file_pkg_updater_updater_proto_msgTypes[10] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use FilesUpdaterVersion_Request.ProtoReflect.Descriptor instead. +func (*FilesUpdaterVersion_Request) Descriptor() ([]byte, []int) { + return file_pkg_updater_updater_proto_rawDescGZIP(), []int{2, 0} +} + +type FilesUpdaterVersion_Response struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"` +} + +func (x *FilesUpdaterVersion_Response) Reset() { + *x = FilesUpdaterVersion_Response{} + if protoimpl.UnsafeEnabled { + mi := &file_pkg_updater_updater_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *FilesUpdaterVersion_Response) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FilesUpdaterVersion_Response) ProtoMessage() {} + +func (x *FilesUpdaterVersion_Response) ProtoReflect() protoreflect.Message { + mi := &file_pkg_updater_updater_proto_msgTypes[11] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use FilesUpdaterVersion_Response.ProtoReflect.Descriptor instead. +func (*FilesUpdaterVersion_Response) Descriptor() ([]byte, []int) { + return file_pkg_updater_updater_proto_rawDescGZIP(), []int{2, 1} +} + +func (x *FilesUpdaterVersion_Response) GetVersion() string { + if x != nil { + return x.Version + } + return "" } type FilesUpdaterForFiles_Request struct { @@ -110,7 +488,7 @@ type FilesUpdaterForFiles_Request struct { func (x *FilesUpdaterForFiles_Request) Reset() { *x = FilesUpdaterForFiles_Request{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_updater_updater_proto_msgTypes[2] + mi := &file_pkg_updater_updater_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -123,7 +501,7 @@ func (x *FilesUpdaterForFiles_Request) String() string { func (*FilesUpdaterForFiles_Request) ProtoMessage() {} func (x *FilesUpdaterForFiles_Request) ProtoReflect() protoreflect.Message { - mi := &file_pkg_updater_updater_proto_msgTypes[2] + mi := &file_pkg_updater_updater_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -136,7 +514,7 @@ func (x *FilesUpdaterForFiles_Request) ProtoReflect() protoreflect.Message { // Deprecated: Use FilesUpdaterForFiles_Request.ProtoReflect.Descriptor instead. func (*FilesUpdaterForFiles_Request) Descriptor() ([]byte, []int) { - return file_pkg_updater_updater_proto_rawDescGZIP(), []int{0, 0} + return file_pkg_updater_updater_proto_rawDescGZIP(), []int{3, 0} } type FilesUpdaterForFiles_Response struct { @@ -150,7 +528,7 @@ type FilesUpdaterForFiles_Response struct { func (x *FilesUpdaterForFiles_Response) Reset() { *x = FilesUpdaterForFiles_Response{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_updater_updater_proto_msgTypes[3] + mi := &file_pkg_updater_updater_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -163,7 +541,7 @@ func (x *FilesUpdaterForFiles_Response) String() string { func (*FilesUpdaterForFiles_Response) ProtoMessage() {} func (x *FilesUpdaterForFiles_Response) ProtoReflect() protoreflect.Message { - mi := &file_pkg_updater_updater_proto_msgTypes[3] + mi := &file_pkg_updater_updater_proto_msgTypes[13] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -176,7 +554,7 @@ func (x *FilesUpdaterForFiles_Response) ProtoReflect() protoreflect.Message { // Deprecated: Use FilesUpdaterForFiles_Response.ProtoReflect.Descriptor instead. func (*FilesUpdaterForFiles_Response) Descriptor() ([]byte, []int) { - return file_pkg_updater_updater_proto_rawDescGZIP(), []int{0, 1} + return file_pkg_updater_updater_proto_rawDescGZIP(), []int{3, 1} } func (x *FilesUpdaterForFiles_Response) GetFiles() string { @@ -198,7 +576,7 @@ type FilesUpdaterApply_Request struct { func (x *FilesUpdaterApply_Request) Reset() { *x = FilesUpdaterApply_Request{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_updater_updater_proto_msgTypes[4] + mi := &file_pkg_updater_updater_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -211,7 +589,7 @@ func (x *FilesUpdaterApply_Request) String() string { func (*FilesUpdaterApply_Request) ProtoMessage() {} func (x *FilesUpdaterApply_Request) ProtoReflect() protoreflect.Message { - mi := &file_pkg_updater_updater_proto_msgTypes[4] + mi := &file_pkg_updater_updater_proto_msgTypes[14] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -224,7 +602,7 @@ func (x *FilesUpdaterApply_Request) ProtoReflect() protoreflect.Message { // Deprecated: Use FilesUpdaterApply_Request.ProtoReflect.Descriptor instead. func (*FilesUpdaterApply_Request) Descriptor() ([]byte, []int) { - return file_pkg_updater_updater_proto_rawDescGZIP(), []int{1, 0} + return file_pkg_updater_updater_proto_rawDescGZIP(), []int{4, 0} } func (x *FilesUpdaterApply_Request) GetFile() string { @@ -252,7 +630,7 @@ type FilesUpdaterApply_Response struct { func (x *FilesUpdaterApply_Response) Reset() { *x = FilesUpdaterApply_Response{} if protoimpl.UnsafeEnabled { - mi := &file_pkg_updater_updater_proto_msgTypes[5] + mi := &file_pkg_updater_updater_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -265,7 +643,7 @@ func (x *FilesUpdaterApply_Response) String() string { func (*FilesUpdaterApply_Response) ProtoMessage() {} func (x *FilesUpdaterApply_Response) ProtoReflect() protoreflect.Message { - mi := &file_pkg_updater_updater_proto_msgTypes[5] + mi := &file_pkg_updater_updater_proto_msgTypes[15] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -278,7 +656,7 @@ func (x *FilesUpdaterApply_Response) ProtoReflect() protoreflect.Message { // Deprecated: Use FilesUpdaterApply_Response.ProtoReflect.Descriptor instead. func (*FilesUpdaterApply_Response) Descriptor() ([]byte, []int) { - return file_pkg_updater_updater_proto_rawDescGZIP(), []int{1, 1} + return file_pkg_updater_updater_proto_rawDescGZIP(), []int{4, 1} } func (x *FilesUpdaterApply_Response) GetError() string { @@ -292,34 +670,66 @@ var File_pkg_updater_updater_proto protoreflect.FileDescriptor var file_pkg_updater_updater_proto_rawDesc = []byte{ 0x0a, 0x19, 0x70, 0x6b, 0x67, 0x2f, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x2f, 0x75, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x43, 0x0a, 0x14, 0x46, - 0x69, 0x6c, 0x65, 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x46, 0x6f, 0x72, 0x46, 0x69, - 0x6c, 0x65, 0x73, 0x1a, 0x09, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, - 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x66, 0x69, - 0x6c, 0x65, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x66, 0x69, 0x6c, 0x65, 0x73, - 0x22, 0x75, 0x0a, 0x11, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, - 0x41, 0x70, 0x70, 0x6c, 0x79, 0x1a, 0x3e, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x12, 0x12, 0x0a, 0x04, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, - 0x66, 0x69, 0x6c, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x6e, 0x65, 0x77, 0x5f, 0x76, 0x65, 0x72, 0x73, - 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6e, 0x65, 0x77, 0x56, 0x65, - 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x1a, 0x20, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x32, 0xa1, 0x01, 0x0a, 0x12, 0x46, 0x69, 0x6c, 0x65, - 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x12, 0x49, - 0x0a, 0x08, 0x46, 0x6f, 0x72, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x12, 0x1d, 0x2e, 0x46, 0x69, 0x6c, - 0x65, 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x46, 0x6f, 0x72, 0x46, 0x69, 0x6c, 0x65, - 0x73, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x46, 0x69, 0x6c, 0x65, - 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x46, 0x6f, 0x72, 0x46, 0x69, 0x6c, 0x65, 0x73, - 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x40, 0x0a, 0x05, 0x41, 0x70, 0x70, - 0x6c, 0x79, 0x12, 0x1a, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, - 0x72, 0x41, 0x70, 0x70, 0x6c, 0x79, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1b, - 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x41, 0x70, 0x70, - 0x6c, 0x79, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x40, 0x5a, 0x3e, 0x67, - 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x6f, 0x2d, 0x73, 0x65, 0x6d, - 0x61, 0x6e, 0x74, 0x69, 0x63, 0x2d, 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2f, 0x73, 0x65, - 0x6d, 0x61, 0x6e, 0x74, 0x69, 0x63, 0x2d, 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2f, 0x76, - 0x32, 0x2f, 0x70, 0x6b, 0x67, 0x2f, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x62, 0x06, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x64, 0x61, 0x74, 0x65, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xba, 0x01, 0x0a, 0x10, + 0x46, 0x69, 0x6c, 0x65, 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x49, 0x6e, 0x69, 0x74, + 0x1a, 0x83, 0x01, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x3d, 0x0a, 0x06, + 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x46, + 0x69, 0x6c, 0x65, 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x49, 0x6e, 0x69, 0x74, 0x2e, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x2e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x45, 0x6e, + 0x74, 0x72, 0x79, 0x52, 0x06, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x1a, 0x39, 0x0a, 0x0b, 0x43, + 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, + 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, + 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, + 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x20, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x22, 0x3d, 0x0a, 0x10, 0x46, 0x69, 0x6c, 0x65, + 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x1a, 0x09, 0x0a, 0x07, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x46, 0x0a, 0x13, 0x46, 0x69, 0x6c, 0x65, 0x73, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x1a, 0x09, + 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x24, 0x0a, 0x08, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x22, + 0x43, 0x0a, 0x14, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x46, + 0x6f, 0x72, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x1a, 0x09, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x20, 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x14, + 0x0a, 0x05, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x66, + 0x69, 0x6c, 0x65, 0x73, 0x22, 0x75, 0x0a, 0x11, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x72, 0x41, 0x70, 0x70, 0x6c, 0x79, 0x1a, 0x3e, 0x0a, 0x07, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x04, 0x66, 0x69, 0x6c, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x6e, 0x65, 0x77, 0x5f, + 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6e, + 0x65, 0x77, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x1a, 0x20, 0x0a, 0x08, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x32, 0xe7, 0x02, 0x0a, 0x12, + 0x46, 0x69, 0x6c, 0x65, 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x50, 0x6c, 0x75, 0x67, + 0x69, 0x6e, 0x12, 0x3d, 0x0a, 0x04, 0x49, 0x6e, 0x69, 0x74, 0x12, 0x19, 0x2e, 0x46, 0x69, 0x6c, + 0x65, 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x49, 0x6e, 0x69, 0x74, 0x2e, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x72, 0x49, 0x6e, 0x69, 0x74, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x12, 0x3d, 0x0a, 0x04, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x19, 0x2e, 0x46, 0x69, 0x6c, 0x65, + 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x2e, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x55, 0x70, 0x64, 0x61, + 0x74, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x46, 0x0a, 0x07, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x1c, 0x2e, 0x46, 0x69, + 0x6c, 0x65, 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, + 0x6e, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x46, 0x69, 0x6c, 0x65, + 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x2e, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x49, 0x0a, 0x08, 0x46, 0x6f, 0x72, 0x46, + 0x69, 0x6c, 0x65, 0x73, 0x12, 0x1d, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x55, 0x70, 0x64, 0x61, + 0x74, 0x65, 0x72, 0x46, 0x6f, 0x72, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x2e, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x72, 0x46, 0x6f, 0x72, 0x46, 0x69, 0x6c, 0x65, 0x73, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x12, 0x40, 0x0a, 0x05, 0x41, 0x70, 0x70, 0x6c, 0x79, 0x12, 0x1a, 0x2e, 0x46, + 0x69, 0x6c, 0x65, 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x41, 0x70, 0x70, 0x6c, 0x79, + 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1b, 0x2e, 0x46, 0x69, 0x6c, 0x65, 0x73, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x41, 0x70, 0x70, 0x6c, 0x79, 0x2e, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x40, 0x5a, 0x3e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, + 0x63, 0x6f, 0x6d, 0x2f, 0x67, 0x6f, 0x2d, 0x73, 0x65, 0x6d, 0x61, 0x6e, 0x74, 0x69, 0x63, 0x2d, + 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2f, 0x73, 0x65, 0x6d, 0x61, 0x6e, 0x74, 0x69, 0x63, + 0x2d, 0x72, 0x65, 0x6c, 0x65, 0x61, 0x73, 0x65, 0x2f, 0x76, 0x32, 0x2f, 0x70, 0x6b, 0x67, 0x2f, + 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x72, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -334,25 +744,42 @@ func file_pkg_updater_updater_proto_rawDescGZIP() []byte { return file_pkg_updater_updater_proto_rawDescData } -var file_pkg_updater_updater_proto_msgTypes = make([]protoimpl.MessageInfo, 6) +var file_pkg_updater_updater_proto_msgTypes = make([]protoimpl.MessageInfo, 16) var file_pkg_updater_updater_proto_goTypes = []interface{}{ - (*FilesUpdaterForFiles)(nil), // 0: FilesUpdaterForFiles - (*FilesUpdaterApply)(nil), // 1: FilesUpdaterApply - (*FilesUpdaterForFiles_Request)(nil), // 2: FilesUpdaterForFiles.Request - (*FilesUpdaterForFiles_Response)(nil), // 3: FilesUpdaterForFiles.Response - (*FilesUpdaterApply_Request)(nil), // 4: FilesUpdaterApply.Request - (*FilesUpdaterApply_Response)(nil), // 5: FilesUpdaterApply.Response + (*FilesUpdaterInit)(nil), // 0: FilesUpdaterInit + (*FilesUpdaterName)(nil), // 1: FilesUpdaterName + (*FilesUpdaterVersion)(nil), // 2: FilesUpdaterVersion + (*FilesUpdaterForFiles)(nil), // 3: FilesUpdaterForFiles + (*FilesUpdaterApply)(nil), // 4: FilesUpdaterApply + (*FilesUpdaterInit_Request)(nil), // 5: FilesUpdaterInit.Request + (*FilesUpdaterInit_Response)(nil), // 6: FilesUpdaterInit.Response + nil, // 7: FilesUpdaterInit.Request.ConfigEntry + (*FilesUpdaterName_Request)(nil), // 8: FilesUpdaterName.Request + (*FilesUpdaterName_Response)(nil), // 9: FilesUpdaterName.Response + (*FilesUpdaterVersion_Request)(nil), // 10: FilesUpdaterVersion.Request + (*FilesUpdaterVersion_Response)(nil), // 11: FilesUpdaterVersion.Response + (*FilesUpdaterForFiles_Request)(nil), // 12: FilesUpdaterForFiles.Request + (*FilesUpdaterForFiles_Response)(nil), // 13: FilesUpdaterForFiles.Response + (*FilesUpdaterApply_Request)(nil), // 14: FilesUpdaterApply.Request + (*FilesUpdaterApply_Response)(nil), // 15: FilesUpdaterApply.Response } var file_pkg_updater_updater_proto_depIdxs = []int32{ - 2, // 0: FilesUpdaterPlugin.ForFiles:input_type -> FilesUpdaterForFiles.Request - 4, // 1: FilesUpdaterPlugin.Apply:input_type -> FilesUpdaterApply.Request - 3, // 2: FilesUpdaterPlugin.ForFiles:output_type -> FilesUpdaterForFiles.Response - 5, // 3: FilesUpdaterPlugin.Apply:output_type -> FilesUpdaterApply.Response - 2, // [2:4] is the sub-list for method output_type - 0, // [0:2] is the sub-list for method input_type - 0, // [0:0] is the sub-list for extension type_name - 0, // [0:0] is the sub-list for extension extendee - 0, // [0:0] is the sub-list for field type_name + 7, // 0: FilesUpdaterInit.Request.config:type_name -> FilesUpdaterInit.Request.ConfigEntry + 5, // 1: FilesUpdaterPlugin.Init:input_type -> FilesUpdaterInit.Request + 8, // 2: FilesUpdaterPlugin.Name:input_type -> FilesUpdaterName.Request + 10, // 3: FilesUpdaterPlugin.Version:input_type -> FilesUpdaterVersion.Request + 12, // 4: FilesUpdaterPlugin.ForFiles:input_type -> FilesUpdaterForFiles.Request + 14, // 5: FilesUpdaterPlugin.Apply:input_type -> FilesUpdaterApply.Request + 6, // 6: FilesUpdaterPlugin.Init:output_type -> FilesUpdaterInit.Response + 9, // 7: FilesUpdaterPlugin.Name:output_type -> FilesUpdaterName.Response + 11, // 8: FilesUpdaterPlugin.Version:output_type -> FilesUpdaterVersion.Response + 13, // 9: FilesUpdaterPlugin.ForFiles:output_type -> FilesUpdaterForFiles.Response + 15, // 10: FilesUpdaterPlugin.Apply:output_type -> FilesUpdaterApply.Response + 6, // [6:11] is the sub-list for method output_type + 1, // [1:6] is the sub-list for method input_type + 1, // [1:1] is the sub-list for extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name } func init() { file_pkg_updater_updater_proto_init() } @@ -362,7 +789,7 @@ func file_pkg_updater_updater_proto_init() { } if !protoimpl.UnsafeEnabled { file_pkg_updater_updater_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FilesUpdaterForFiles); i { + switch v := v.(*FilesUpdaterInit); i { case 0: return &v.state case 1: @@ -374,7 +801,7 @@ func file_pkg_updater_updater_proto_init() { } } file_pkg_updater_updater_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FilesUpdaterApply); i { + switch v := v.(*FilesUpdaterName); i { case 0: return &v.state case 1: @@ -386,7 +813,7 @@ func file_pkg_updater_updater_proto_init() { } } file_pkg_updater_updater_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FilesUpdaterForFiles_Request); i { + switch v := v.(*FilesUpdaterVersion); i { case 0: return &v.state case 1: @@ -398,7 +825,7 @@ func file_pkg_updater_updater_proto_init() { } } file_pkg_updater_updater_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FilesUpdaterForFiles_Response); i { + switch v := v.(*FilesUpdaterForFiles); i { case 0: return &v.state case 1: @@ -410,7 +837,7 @@ func file_pkg_updater_updater_proto_init() { } } file_pkg_updater_updater_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*FilesUpdaterApply_Request); i { + switch v := v.(*FilesUpdaterApply); i { case 0: return &v.state case 1: @@ -422,6 +849,114 @@ func file_pkg_updater_updater_proto_init() { } } file_pkg_updater_updater_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FilesUpdaterInit_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_updater_updater_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FilesUpdaterInit_Response); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_updater_updater_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FilesUpdaterName_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_updater_updater_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FilesUpdaterName_Response); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_updater_updater_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FilesUpdaterVersion_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_updater_updater_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FilesUpdaterVersion_Response); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_updater_updater_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FilesUpdaterForFiles_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_updater_updater_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FilesUpdaterForFiles_Response); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_updater_updater_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*FilesUpdaterApply_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_pkg_updater_updater_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*FilesUpdaterApply_Response); i { case 0: return &v.state @@ -440,7 +975,7 @@ func file_pkg_updater_updater_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_pkg_updater_updater_proto_rawDesc, NumEnums: 0, - NumMessages: 6, + NumMessages: 16, NumExtensions: 0, NumServices: 1, }, diff --git a/pkg/updater/updater.proto b/pkg/updater/updater.proto index 985f496577ed97c8c1291d6386fb97c2da5043eb..35e1ebc2d98b4c9a8ffc7c67195c63e6cb8b95bd 100644 --- a/pkg/updater/updater.proto +++ b/pkg/updater/updater.proto @@ -1,6 +1,29 @@ syntax = "proto3"; option go_package = "github.com/go-semantic-release/semantic-release/v2/pkg/updater"; +message FilesUpdaterInit { + message Request { + map<string, string> config = 1; + } + message Response { + string error = 1; + } +} + +message FilesUpdaterName { + message Request {} + message Response { + string name = 1; + } +} + +message FilesUpdaterVersion { + message Request {} + message Response { + string version = 1; + } +} + message FilesUpdaterForFiles { message Request {} message Response { @@ -19,6 +42,9 @@ message FilesUpdaterApply { } service FilesUpdaterPlugin { + rpc Init(FilesUpdaterInit.Request) returns (FilesUpdaterInit.Response); + rpc Name(FilesUpdaterName.Request) returns (FilesUpdaterName.Response); + rpc Version(FilesUpdaterVersion.Request) returns (FilesUpdaterVersion.Response); rpc ForFiles(FilesUpdaterForFiles.Request) returns (FilesUpdaterForFiles.Response); rpc Apply(FilesUpdaterApply.Request) returns (FilesUpdaterApply.Response); } diff --git a/pkg/updater/updater_grpc.pb.go b/pkg/updater/updater_grpc.pb.go index 37c576e8fe2c68ac6e89eaaaa3ae40ea9301e77f..f202559baf39f4229088ea2cbbcefb8043ee18e3 100644 --- a/pkg/updater/updater_grpc.pb.go +++ b/pkg/updater/updater_grpc.pb.go @@ -17,6 +17,9 @@ const _ = grpc.SupportPackageIsVersion6 // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. type FilesUpdaterPluginClient interface { + Init(ctx context.Context, in *FilesUpdaterInit_Request, opts ...grpc.CallOption) (*FilesUpdaterInit_Response, error) + Name(ctx context.Context, in *FilesUpdaterName_Request, opts ...grpc.CallOption) (*FilesUpdaterName_Response, error) + Version(ctx context.Context, in *FilesUpdaterVersion_Request, opts ...grpc.CallOption) (*FilesUpdaterVersion_Response, error) ForFiles(ctx context.Context, in *FilesUpdaterForFiles_Request, opts ...grpc.CallOption) (*FilesUpdaterForFiles_Response, error) Apply(ctx context.Context, in *FilesUpdaterApply_Request, opts ...grpc.CallOption) (*FilesUpdaterApply_Response, error) } @@ -29,6 +32,33 @@ func NewFilesUpdaterPluginClient(cc grpc.ClientConnInterface) FilesUpdaterPlugin return &filesUpdaterPluginClient{cc} } +func (c *filesUpdaterPluginClient) Init(ctx context.Context, in *FilesUpdaterInit_Request, opts ...grpc.CallOption) (*FilesUpdaterInit_Response, error) { + out := new(FilesUpdaterInit_Response) + err := c.cc.Invoke(ctx, "/FilesUpdaterPlugin/Init", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *filesUpdaterPluginClient) Name(ctx context.Context, in *FilesUpdaterName_Request, opts ...grpc.CallOption) (*FilesUpdaterName_Response, error) { + out := new(FilesUpdaterName_Response) + err := c.cc.Invoke(ctx, "/FilesUpdaterPlugin/Name", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *filesUpdaterPluginClient) Version(ctx context.Context, in *FilesUpdaterVersion_Request, opts ...grpc.CallOption) (*FilesUpdaterVersion_Response, error) { + out := new(FilesUpdaterVersion_Response) + err := c.cc.Invoke(ctx, "/FilesUpdaterPlugin/Version", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *filesUpdaterPluginClient) ForFiles(ctx context.Context, in *FilesUpdaterForFiles_Request, opts ...grpc.CallOption) (*FilesUpdaterForFiles_Response, error) { out := new(FilesUpdaterForFiles_Response) err := c.cc.Invoke(ctx, "/FilesUpdaterPlugin/ForFiles", in, out, opts...) @@ -51,6 +81,9 @@ func (c *filesUpdaterPluginClient) Apply(ctx context.Context, in *FilesUpdaterAp // All implementations must embed UnimplementedFilesUpdaterPluginServer // for forward compatibility type FilesUpdaterPluginServer interface { + Init(context.Context, *FilesUpdaterInit_Request) (*FilesUpdaterInit_Response, error) + Name(context.Context, *FilesUpdaterName_Request) (*FilesUpdaterName_Response, error) + Version(context.Context, *FilesUpdaterVersion_Request) (*FilesUpdaterVersion_Response, error) ForFiles(context.Context, *FilesUpdaterForFiles_Request) (*FilesUpdaterForFiles_Response, error) Apply(context.Context, *FilesUpdaterApply_Request) (*FilesUpdaterApply_Response, error) mustEmbedUnimplementedFilesUpdaterPluginServer() @@ -60,6 +93,15 @@ type FilesUpdaterPluginServer interface { type UnimplementedFilesUpdaterPluginServer struct { } +func (*UnimplementedFilesUpdaterPluginServer) Init(context.Context, *FilesUpdaterInit_Request) (*FilesUpdaterInit_Response, error) { + return nil, status.Errorf(codes.Unimplemented, "method Init not implemented") +} +func (*UnimplementedFilesUpdaterPluginServer) Name(context.Context, *FilesUpdaterName_Request) (*FilesUpdaterName_Response, error) { + return nil, status.Errorf(codes.Unimplemented, "method Name not implemented") +} +func (*UnimplementedFilesUpdaterPluginServer) Version(context.Context, *FilesUpdaterVersion_Request) (*FilesUpdaterVersion_Response, error) { + return nil, status.Errorf(codes.Unimplemented, "method Version not implemented") +} func (*UnimplementedFilesUpdaterPluginServer) ForFiles(context.Context, *FilesUpdaterForFiles_Request) (*FilesUpdaterForFiles_Response, error) { return nil, status.Errorf(codes.Unimplemented, "method ForFiles not implemented") } @@ -72,6 +114,60 @@ func RegisterFilesUpdaterPluginServer(s *grpc.Server, srv FilesUpdaterPluginServ s.RegisterService(&_FilesUpdaterPlugin_serviceDesc, srv) } +func _FilesUpdaterPlugin_Init_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(FilesUpdaterInit_Request) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(FilesUpdaterPluginServer).Init(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/FilesUpdaterPlugin/Init", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(FilesUpdaterPluginServer).Init(ctx, req.(*FilesUpdaterInit_Request)) + } + return interceptor(ctx, in, info, handler) +} + +func _FilesUpdaterPlugin_Name_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(FilesUpdaterName_Request) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(FilesUpdaterPluginServer).Name(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/FilesUpdaterPlugin/Name", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(FilesUpdaterPluginServer).Name(ctx, req.(*FilesUpdaterName_Request)) + } + return interceptor(ctx, in, info, handler) +} + +func _FilesUpdaterPlugin_Version_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(FilesUpdaterVersion_Request) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(FilesUpdaterPluginServer).Version(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/FilesUpdaterPlugin/Version", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(FilesUpdaterPluginServer).Version(ctx, req.(*FilesUpdaterVersion_Request)) + } + return interceptor(ctx, in, info, handler) +} + func _FilesUpdaterPlugin_ForFiles_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(FilesUpdaterForFiles_Request) if err := dec(in); err != nil { @@ -112,6 +208,18 @@ var _FilesUpdaterPlugin_serviceDesc = grpc.ServiceDesc{ ServiceName: "FilesUpdaterPlugin", HandlerType: (*FilesUpdaterPluginServer)(nil), Methods: []grpc.MethodDesc{ + { + MethodName: "Init", + Handler: _FilesUpdaterPlugin_Init_Handler, + }, + { + MethodName: "Name", + Handler: _FilesUpdaterPlugin_Name_Handler, + }, + { + MethodName: "Version", + Handler: _FilesUpdaterPlugin_Version_Handler, + }, { MethodName: "ForFiles", Handler: _FilesUpdaterPlugin_ForFiles_Handler, diff --git a/pkg/updater/updater_test.go b/pkg/updater/updater_test.go index f4fdec1dd8e441a6e310b57bce7a7fc29d294612..0863a7841eedccd688baafb57e83dc0d3d797527 100644 --- a/pkg/updater/updater_test.go +++ b/pkg/updater/updater_test.go @@ -11,6 +11,18 @@ type testFileUpdater struct { nVer string } +func (tfu *testFileUpdater) Init(map[string]string) error { + return nil +} + +func (tfu *testFileUpdater) Name() string { + return "test" +} + +func (tfu *testFileUpdater) Version() string { + return "1.0.0" +} + func (tfu *testFileUpdater) ForFiles() string { return "package\\.json" } diff --git a/pkg/updater/updater_wrapper.go b/pkg/updater/updater_wrapper.go index e742c20717d1c30f44b562b4b90b2b424ac5a887..5acebb500ef6e6cbe6d4b2b4813d64600bdfbb26 100644 --- a/pkg/updater/updater_wrapper.go +++ b/pkg/updater/updater_wrapper.go @@ -12,6 +12,14 @@ type FilesUpdaterServer struct { UnimplementedFilesUpdaterPluginServer } +func (f *FilesUpdaterServer) Name(ctx context.Context, request *FilesUpdaterName_Request) (*FilesUpdaterName_Response, error) { + return &FilesUpdaterName_Response{Name: f.Impl.Name()}, nil +} + +func (f *FilesUpdaterServer) Version(ctx context.Context, request *FilesUpdaterVersion_Request) (*FilesUpdaterVersion_Response, error) { + return &FilesUpdaterVersion_Response{Version: f.Impl.Version()}, nil +} + func (f *FilesUpdaterServer) ForFiles(ctx context.Context, request *FilesUpdaterForFiles_Request) (*FilesUpdaterForFiles_Response, error) { return &FilesUpdaterForFiles_Response{Files: f.Impl.ForFiles()}, nil } @@ -29,6 +37,22 @@ type FilesUpdaterClient struct { Impl FilesUpdaterPluginClient } +func (f *FilesUpdaterClient) Name() string { + res, err := f.Impl.Name(context.Background(), &FilesUpdaterName_Request{}) + if err != nil { + panic(err) + } + return res.Name +} + +func (f *FilesUpdaterClient) Version() string { + res, err := f.Impl.Version(context.Background(), &FilesUpdaterVersion_Request{}) + if err != nil { + panic(err) + } + return res.Version +} + func (f *FilesUpdaterClient) ForFiles() string { res, err := f.Impl.ForFiles(context.Background(), &FilesUpdaterForFiles_Request{}) if err != nil {