Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: add prow OWNERS file #1231

Merged
merged 15 commits into from
Apr 12, 2024
Merged
3 changes: 3 additions & 0 deletions OWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# See the OWNERS docs at https://go.k8s.io/owners
approvers:
- sig-approvers
25 changes: 25 additions & 0 deletions OWNERS_ALIASES
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Sort the member alphabetically.
aliases:
sig-approvers: # default approvers for the repo on rest folders.
- cfzjywxk
- lance6716
- overvenus
- you06
- YuJuncen
sig-approvers-pb: # default approvers for `proto` folder
- kevin-xialiu
- yudongusa
- zhangjinpeng1987
sig-approvers-pb-autoid: [bb7133, tiancaiamao]
sig-approvers-pb-br: [BornChanger, overvenus]
sig-approvers-pb-cdc: [flowbehappy, overvenus]
sig-approvers-pb-config: [overvenus]
sig-approvers-pb-coprocessor: [cfzjywxk]
sig-approvers-pb-deadlock: [MyonKeminta, cfzjywxk]
sig-approvers-pb-debug: [cfzjywxk]
sig-approvers-pb-pd: [niubell, rleungx]
sig-approvers-pb-raftstore: [tonyxuqqi, overvenus]
wuhuizuo marked this conversation as resolved.
Show resolved Hide resolved
sig-approvers-pb-tikv: [tonyxuqqi]
sig-approvers-pb-error: [cfzjywxk]
sig-approvers-pb-kvrpc: [cfzjywxk]
sig-approvers-pb-trace: [you06]
19 changes: 18 additions & 1 deletion build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,27 @@
// limitations under the License.

use protobuf_build::Builder;
use std::fs;

fn main() {
let proto_dir = "proto";
let mut proto_files = Vec::new();

// Walk the proto directory and collect all .proto files.
for entry in fs::read_dir(proto_dir).unwrap() {
let entry = entry.unwrap();
let path = entry.path();
if path.is_file() {
if let Some(ext) = path.extension() {
if ext == "proto" {
proto_files.push(path.to_string_lossy().into_owned());
}
}
}
}

Builder::new()
.search_dir_for_protos("proto")
.files(&proto_files)
overvenus marked this conversation as resolved.
Show resolved Hide resolved
.append_to_black_list("eraftpb")
.generate()
}
76 changes: 76 additions & 0 deletions proto/OWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
# See the OWNERS docs at https://go.k8s.io/owners
options:
no_parent_owners: true
filters:
"^autoid\\.proto$":
approvers: [sig-approvers-pb-autoid]
"^brpb\\.proto$":
approvers: [sig-approvers-pb-br]
"^cdcpb\\.proto$":
approvers: [sig-approvers-pb-cdc]
"^configpb\\.proto$":
approvers: [sig-approvers-pb-config]
"^coprocessor\\.proto$":
approvers: [sig-approvers-pb-coprocessor]
"^deadlock\\.proto$":
approvers: [sig-approvers-pb-deadlock]
"^debugpb\\.proto$":
approvers: [sig-approvers-pb-debug]
"^disk_usage\\.proto$":
approvers: [sig-approvers-pb-raftstore]
"^errorpb\\.proto$":
approvers: [sig-approvers-pb-error]
"^encryptionpb\\.proto$":
approvers: [sig-approvers-pb-raftstore]
"^enginepb\\.proto$":
approvers: [sig-approvers-pb-raftstore]
"^import_kvpb\\.proto$":
approvers: [sig-approvers-pb-br]
"^import_sstpb\\.proto$":
approvers: [sig-approvers-pb-br]
"^kvrpcpb\\.proto$":
approvers: [sig-approvers-kvrpc]
"^logbackuppb\\.proto$":
approvers: [sig-approvers-pb-br]
"^metapb\\.proto$":
approvers: [sig-approvers-pb-raftstore]
"^raft_cmdpb\\.proto$":
approvers: [sig-approvers-pb-raftstore]
"^raft_serverpb\\.proto$":
approvers: [sig-approvers-pb-raftstore]
"^recoverdatapb\\.proto$":
approvers: [sig-approvers-pb-br]
"^resource_manager\\.proto$":
approvers: [sig-approvers-pb-raftstore]
"^tikvpb\\.proto$":
approvers: [sig-approvers-pb-tikv, sig-approvers-pb-kvprc]
"^tracepb\\.proto$":
approvers: [sig-approvers-pb-trace]
"^pdpb\\.proto$":
approvers: [sig-approvers-pb-pd]
"^keyspacepb\\.proto$":
approvers: [sig-approvers-pb-pd]
"^schedulingpb\\.proto$":
approvers: [sig-approvers-pb-pd]
"^tsopb\\.proto$":
approvers: [sig-approvers-pb-pd]
"^meta_storagepb\\.proto$":
approvers: [sig-approvers-pb-pd]

### If the special file need to be controlled by a SIG, please uncomment it and fill the approvers.
# "^diagnosticspb\\.proto$":
# approvers: []
# "^disaggregated\\.proto$":
# approvers: []
# "^gcpb\\.proto$":
# approvers: []
# "^mpp\\.proto$":
# approvers: []
# "^replication_modepb\\.proto$":
# approvers: []
# "^resource_usage_agent\\.proto$":
# approvers: []

# For rest files.
".*":
approvers: [sig-approvers-pb]
2 changes: 1 addition & 1 deletion scripts/check.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ check-protos-compatible() {
export PATH=$GOPATH/bin:$PATH

if [ ! -f "$GOPATH/bin/protolock" ]; then
GO111MODULE=off go install github.com/nilslice/protolock/cmd/[email protected]
go install github.com/nilslice/protolock/cmd/[email protected] || exit 1
fi

if protolock status -lockdir=scripts -protoroot=proto; then
Expand Down
Loading