From b438b836ea5e031c1e48cb8b2a777f1647d70f8a Mon Sep 17 00:00:00 2001 From: hackercat Date: Mon, 29 Mar 2021 06:35:01 +0200 Subject: [PATCH] fix: invoke login shells to source `/etc/environment` (#570) --- pkg/model/workflow.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkg/model/workflow.go b/pkg/model/workflow.go index 41a7167c..410bb806 100644 --- a/pkg/model/workflow.go +++ b/pkg/model/workflow.go @@ -259,13 +259,13 @@ func (s *Step) ShellCommand() string { switch s.Shell { case "", "bash": - shellCommand = "bash --noprofile --norc -e {0}" + shellCommand = "bash --login --norc -e {0}" case "pwsh": - shellCommand = "pwsh -command \"& '{0}'\"" + shellCommand = "pwsh -login -command \"& '{0}'\"" case "python": shellCommand = "python {0}" case "sh": - shellCommand = "sh -e -c {0}" + shellCommand = "sh -l -e -c {0}" case "cmd": shellCommand = "%ComSpec% /D /E:ON /V:OFF /S /C \"CALL \"{0}\"\"" case "powershell":