mirror of
https://code.forgejo.org/forgejo/runner.git
synced 2025-09-15 18:57:01 +00:00
parent
41dabfd633
commit
1a3ec6c470
4 changed files with 24 additions and 0 deletions
|
@ -110,6 +110,13 @@ func (sc *StepContext) setupShellCommand() common.Executor {
|
|||
return err
|
||||
}
|
||||
|
||||
if step.WorkingDirectory != "" {
|
||||
_, err = script.WriteString(fmt.Sprintf("cd %s\n", step.WorkingDirectory))
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
||||
run := rc.ExprEval.Interpolate(step.Run)
|
||||
|
||||
if _, err = script.WriteString(run); err != nil {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue