1
0
mirror of https://github.com/go-task/task.git synced 2025-06-15 00:15:10 +02:00

feat: add support for multiple includes on a graph edge

This commit is contained in:
Pete Davison
2024-04-21 15:28:02 +00:00
parent 6951e5cd0c
commit f19c520f23
10 changed files with 41 additions and 56 deletions

View File

@ -3,7 +3,6 @@ package errors
import (
"fmt"
"net/http"
"strings"
"time"
"github.com/Masterminds/semver/v3"
@ -176,22 +175,6 @@ func (err *TaskfileNetworkTimeoutError) Code() int {
return CodeTaskfileNetworkTimeout
}
type TaskfileDuplicateIncludeError struct {
URI string
IncludedURI string
Namespaces []string
}
func (err *TaskfileDuplicateIncludeError) Error() string {
return fmt.Sprintf(
`task: Taskfile %q attempted to include %q multiple times with namespaces: %s`, err.URI, err.IncludedURI, strings.Join(err.Namespaces, ", "),
)
}
func (err *TaskfileDuplicateIncludeError) Code() int {
return CodeTaskfileDuplicateInclude
}
// TaskfileCycleError is returned when we detect that a Taskfile includes a
// set of Taskfiles that include each other in a cycle.
type TaskfileCycleError struct {