mirror of
https://github.com/go-task/task.git
synced 2026-07-02 17:08:45 +00:00
execext package: support context command
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package execext
|
||||
|
||||
import (
|
||||
"context"
|
||||
"os/exec"
|
||||
)
|
||||
|
||||
@@ -17,6 +18,6 @@ func init() {
|
||||
ShExists = err == nil
|
||||
}
|
||||
|
||||
func newShCommand(c string) *exec.Cmd {
|
||||
return exec.Command(ShPath, "-c", c)
|
||||
func newShCommand(ctx context.Context, c string) *exec.Cmd {
|
||||
return exec.CommandContext(ctx, ShPath, "-c", c)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user