()
| 54 | } |
| 55 | |
| 56 | func (e *Executor) getRootNode() (taskfile.Node, error) { |
| 57 | node, err := taskfile.NewRootNode(e.Entrypoint, e.Dir, e.Insecure, e.Timeout, |
| 58 | taskfile.WithCACert(e.CACert), |
| 59 | taskfile.WithCert(e.Cert), |
| 60 | taskfile.WithCertKey(e.CertKey), |
| 61 | ) |
| 62 | var taskNotFoundError errors.TaskfileNotFoundError |
| 63 | if errors.As(err, &taskNotFoundError) { |
| 64 | taskNotFoundError.AskInit = true |
| 65 | return nil, taskNotFoundError |
| 66 | } |
| 67 | if err != nil { |
| 68 | return nil, err |
| 69 | } |
| 70 | e.Dir = node.Dir() |
| 71 | e.Entrypoint = node.Location() |
| 72 | return node, err |
| 73 | } |
| 74 | |
| 75 | func (e *Executor) readTaskfile(node taskfile.Node) error { |
| 76 | ctx, cf := context.WithTimeout(context.Background(), e.Timeout) |
no test coverage detected