Support Stdin when using downloaders of plugin

Inject os.Stdin into the command of helm plugin's downloaders
pull/4307/head
roc 6 years ago
parent aa98e7e3dd
commit 81994381c1

@ -69,6 +69,7 @@ func (p *pluginGetter) Get(href string) (*bytes.Buffer, error) {
buf := bytes.NewBuffer(nil)
prog.Stdout = buf
prog.Stderr = os.Stderr
prog.Stdin = os.Stdin
if err := prog.Run(); err != nil {
if eerr, ok := err.(*exec.ExitError); ok {
os.Stderr.Write(eerr.Stderr)

Loading…
Cancel
Save