mirror of
https://github.com/go-task/task.git
synced 2026-06-11 09:51:50 +00:00
Merge branch 'internal-tasks' of https://github.com/pd93/task into pd93-internal-tasks
This commit is contained in:
7
task.go
7
task.go
@@ -64,11 +64,16 @@ type Executor struct {
|
||||
func (e *Executor) Run(ctx context.Context, calls ...taskfile.Call) error {
|
||||
// check if given tasks exist
|
||||
for _, c := range calls {
|
||||
if _, ok := e.Taskfile.Tasks[c.Task]; !ok {
|
||||
t, ok := e.Taskfile.Tasks[c.Task]
|
||||
if !ok {
|
||||
// FIXME: move to the main package
|
||||
e.ListTasksWithDesc()
|
||||
return &taskNotFoundError{taskName: c.Task}
|
||||
}
|
||||
if t.Internal {
|
||||
e.ListTasksWithDesc()
|
||||
return &taskInternalError{taskName: c.Task}
|
||||
}
|
||||
}
|
||||
|
||||
if e.Summary {
|
||||
|
||||
Reference in New Issue
Block a user