Commit Graph

12 Commits

Author SHA1 Message Date
Wyatt Hepler
8b8c34647b pw_cli: Make process.py faster
- For run_async, replace the silent option with the log_output option.
  With log_output, lines are read one-by-one and logged. Otherwise, the
  output is dumped to a temporary file.
- For tests, only log the output on failure. This substantially speeds
  up verbose tests. A pw_kvs test went from 38 s to 1.2 s when
  passing, or 26 s when failing and printing the output.

Change-Id: Iba18c555c07eeaa9eb5ba79bc8d36d3ef2435485
2020-03-13 19:36:59 +00:00
Alexei Frolov
4a257c1bc5 pw_protobuf: expand docs
This change updates the protobuf docs to explain the module's design
decisions.

Change-Id: Idccacf28651cf091218dabb1d1ad09365d445776
2020-03-03 18:40:46 +00:00
Rob Mohr
a0ba54f648 Roll GN to 239533d
This caused gn format to flag many things which were also fixed.

Change-Id: Ie1d9081a1b08047bec52c60f54d2a94366be1ba6
2020-02-28 01:33:18 +00:00
Alexei Frolov
44d5473453 Various small docs fixes
This fixes some typos in the docs.

Change-Id: I4dc2e3b8fa7685bc994123929513a58e8d0e9c79
2020-01-11 01:03:51 +00:00
Alexei Frolov
c15a98852f
Download external Go dependencies in build
This change updates the Go GN integration to download external
dependencies for Go packages before running "go build". These
dependencies are listed in the pw_go_package template using build
metadata and collected to a "go get" invocation.

To support this, the pw_exec template is expanded to allow setting
positional arguments from a file.

Change-Id: If4f6c71f037b35bb041984da9982a1629d1d36b0
2019-12-26 10:39:48 -08:00
Alexei Frolov
def1471ede Add Go support to GN
This change defines GN templates that allow building Go code as part of
Pigweed's build system. Go is also added as a supported language for the
proto_library template.

Change-Id: I3e639a12e6a8ba0a7a928c5d653c623cff58eb86
2019-12-26 18:37:34 +00:00
Alexei Frolov
bbf164c985 Add pw_protobuf module
This change adds a pw_protobuf module containing a lightweight protobuf
wire format encoder. The encoder comes with a Python script that plugs
into protoc to generate C++ classes from Protobuf files that wrap its
functionality.

Bug: 20

Change-Id: I867655ab64c2f6ddd2a731054b1fbe7ccc97ba70
2019-12-18 21:29:17 +00:00
Rob Mohr
d533ffe911 generate_protos.py passes format check.
Change-Id: I9995cad6a70f8b6f7670b1fac6dc232936faa5e5
2019-12-17 15:10:44 -08:00
Wyatt Hepler
1ccce6b953 pw_cli: Disable colors if the output is not a tty
Bug: 19

Change-Id: Ibdc1f72643415acb12dbf731cd45a9cb786a9fd2
2019-12-17 18:40:46 +00:00
Rob Mohr
21117d8c25 Run 'pw format --fix' on a few files.
Change-Id: I2300a824443ba9bca56ab1116fb451cb3003ea02
2019-12-16 19:06:00 +00:00
Rob Mohr
17ef145c03 Fix some pylint warnings.
Change-Id: I4ba23a344d3fec3111d3ed0ff65fc572ad40fa18
2019-12-16 10:45:52 -08:00
Alexei Frolov
942adf02d6 Add pw_protobuf_compiler module
This change adds a module responsible for invoking the protobuf compiler
to generate code from .proto definition files. It provides a GN template
which performs the codegen operation on a list of input .proto files.
The template currently only supports C++.

Change-Id: I5558fd5b4282e0d6f09f8fafebda972738dc1e83
2019-12-13 19:38:27 +00:00