From 6e880c9027f538968c815f5ff36f16b1f751ae95 Mon Sep 17 00:00:00 2001 From: Andrey Nering Date: Sat, 8 Jul 2017 15:01:45 -0300 Subject: [PATCH] refactor: don't need to run template on Executor.Dir --- task.go | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/task.go b/task.go index 395fc929..14871e48 100644 --- a/task.go +++ b/task.go @@ -297,16 +297,12 @@ func (e *Executor) runCommand(ctx context.Context, call Call, i int) error { func (e *Executor) getTaskDir(call Call) (string, error) { t := e.Tasks[call.Task] - exeDir, err := e.ReplaceVariables(e.Dir, call) - if err != nil { - return "", err - } taskDir, err := e.ReplaceVariables(t.Dir, call) if err != nil { return "", err } - return filepath.Join(exeDir, taskDir), nil + return filepath.Join(e.Dir, taskDir), nil } func (e *Executor) getEnviron(call Call) ([]string, error) {