diff options
| author | Austin Clements <austin@google.com> | 2023-09-20 17:01:40 -0400 |
|---|---|---|
| committer | Gopher Robot <gobot@golang.org> | 2023-10-19 19:09:38 +0000 |
| commit | 4c31dfe850165979bbcf0510c35576d022f26eb3 (patch) | |
| tree | e0236c25d6822766ab5f55bd521d136f3d59636c /test/fixedbugs/bug385_32.go | |
| parent | eabf3bf6887a16c33ba6039d2ed98ff8f261de96 (diff) | |
| download | go-4c31dfe850165979bbcf0510c35576d022f26eb3.tar.xz | |
cmd/go: introduce Shell abstraction
This CL separates running shell commands and doing shell-like
operations out of the Builder type and into their own, new Shell type.
Shell is responsible for tracking output streams and the Action that's
running commands. Shells form a tree somewhat like Context, where new
Shells can be derived from a root shell to adjust their state.
The primary intent is to support "go build -json", where we need to
flow the current package ID down to the lowest level of command output
printing. Shell gives us a way to easily flow that context down.
However, this also puts a clear boundary around how we run commands,
removing this from the rather large Builder abstraction.
For #62067.
Change-Id: Ia9ab2a2d7cac0269ca627bbb316dbd9610bcda44
Reviewed-on: https://go-review.googlesource.com/c/go/+/535016
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Bryan Mills <bcmills@google.com>
Auto-Submit: Austin Clements <austin@google.com>
Diffstat (limited to 'test/fixedbugs/bug385_32.go')
0 files changed, 0 insertions, 0 deletions
