OLD | NEW |
1 This directory contains CQ client library to be distributed to other repos. If | 1 This directory contains CQ client library to be distributed to other repos. If |
2 you need to modify some files in this directory, please make sure that you are | 2 you need to modify some files in this directory, please make sure that you are |
3 changing the canonical version of the source code and not one of the copies, | 3 changing the canonical version of the source code and not one of the copies, |
4 which should only be updated as a whole using Glyco (when available, see | 4 which should only be updated as a whole using Glyco (when available, see |
5 [chromium issue 489420](http://crbug.com/489420)). | 5 [chromium issue 489420](http://crbug.com/489420)). |
6 | 6 |
7 The canonical version is located at `https://chrome-internal.googlesource.com/ | 7 The canonical version is located at `https://chrome-internal.googlesource.com/ |
8 infra/infra_internal/+/master/commit_queue/cq_client`. | 8 infra/infra_internal/+/master/commit_queue/cq_client`. |
9 | 9 |
10 You'll need to use protoc version 2.6.1 and | 10 You'll need to use protoc version 2.6.1 and |
11 recent golang/protobuf package. Sadly, the latter has no tags no versions. | 11 recent golang/protobuf package. Sadly, the latter has neither tags nor versions. |
12 | 12 |
13 You can get protobuf by downloading archive from https://github.com/google/proto
buf/tree/v2.6.1, | 13 You can get protobuf by downloading archive from |
14 and manually building it. As for golang compiler, if you have go configured, | 14 https://github.com/google/protobuf/tree/v2.6.1 and manually building it. As for |
15 just | 15 golang compiler, if you have go configured, just |
16 | 16 |
17 go get -u github.com/golang/protobuf/{proto,protoc-gen-go} | 17 go get -u github.com/golang/protobuf/{proto,protoc-gen-go} |
18 | 18 |
19 TODO(tandrii,sergiyb): decide how to pin the go protobuf generator. | 19 TODO(tandrii,sergiyb): decide how to pin the go protobuf generator. |
20 | 20 |
21 To generate `cq_pb2.py` and `cq.pb.go`: | 21 To generate `cq_pb2.py` and `cq.pb.go`: |
22 | 22 |
23 cd commit_queue/cq_client | 23 cd commit_queue/cq_client |
24 protoc cq.proto --python_out $(pwd) --go_out $(pwd) | 24 protoc cq.proto --python_out $(pwd) --go_out $(pwd) |
25 | 25 |
26 Additionally, please make sure to use proto3-compatible syntax, e.g. no default | 26 Additionally, please make sure to use proto3-compatible syntax, e.g. no default |
27 values, no required fields. Ideally, we should use proto3 generator already, | 27 values, no required fields. Ideally, we should use proto3 generator already, |
28 however alpha version thereof is still unstable. | 28 however alpha version thereof is still unstable. |
29 | 29 |
OLD | NEW |