From d754ded39e0061cb9814551478e6541ed44f4733 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kriszti=C3=A1n=20G=C3=B6drei?= Date: Tue, 8 Aug 2023 15:49:06 +0200 Subject: [PATCH] Update default plugin versions (#883) * Update default plugin versions * Fix plugin's stdin * Set stderr for plugin runs --- bitrise/setup.go | 6 +++--- plugins/run.go | 8 +++++++- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/bitrise/setup.go b/bitrise/setup.go index 7b6c959d6..8ddea67fc 100644 --- a/bitrise/setup.go +++ b/bitrise/setup.go @@ -32,15 +32,15 @@ var PluginDependencyMap = map[string]PluginDependency{ }, "step": { Source: "https://github.com/bitrise-io/bitrise-plugins-step.git", - MinVersion: "0.10.3", + MinVersion: "0.10.4", }, "workflow-editor": { Source: "https://github.com/bitrise-io/bitrise-workflow-editor.git", - MinVersion: "1.3.234", + MinVersion: "1.3.241", }, "analytics": { Source: "https://github.com/bitrise-io/bitrise-plugins-analytics.git", - MinVersion: "0.13.0", + MinVersion: "0.13.1", }, } diff --git a/plugins/run.go b/plugins/run.go index f2f605873..7d0dc0995 100644 --- a/plugins/run.go +++ b/plugins/run.go @@ -2,6 +2,7 @@ package plugins import ( "bytes" + "os" "strings" "github.com/bitrise-io/bitrise/configs" @@ -122,7 +123,11 @@ func runPlugin(plugin Plugin, args []string, envKeyValues PluginConfig, input [] cmd = command.New("bash", append([]string{pluginExecutable}, args...)...) } - cmd.SetStdin(bytes.NewReader(input)) + if len(input) > 0 { + cmd.SetStdin(bytes.NewReader(input)) + } else { + cmd.SetStdin(os.Stdin) + } var envs []string for key, value := range envKeyValues { @@ -138,6 +143,7 @@ func runPlugin(plugin Plugin, args []string, envKeyValues PluginConfig, input [] logWriter := logwriter.NewLogWriter(logger) cmd.SetStdout(logWriter) + cmd.SetStderr(logWriter) cmdErr := cmd.Run()