From: Junio C Hamano Date: Sun, 22 Mar 2015 23:40:37 GMT Subject: Re: [PATCH 3/7] strbuf: introduce strbuf_read_cmd helper Message-ID: In-Reply-To: Junio C Hamano writes: > Eric Sunshine writes: > >> It does feel like a layering violation. If moved to the run-command >> API, it could given one of the following names or something better: >> >> run_command_capture() >> capture_command() >> command_capture() >> run_command_with_output() >> capture_output() > > Sound like a good suggestion (but I haven't read the users of the > proposed function, after doing which I might change my mind---I'll > see). Now I read the callers, it does look like this new function better fits in the run-command suite, essentially allowing us to do what we would do with $(cmd) or `cmd` in shell and Perl scripts, even though I do not particularly agree with the phrase "layering violation" to call its current placement. Thanks.