1
0
mirror of https://github.com/go-task/task.git synced 2025-01-12 04:34:11 +02:00

Fix suggestion to use task --init not being shown anymore

This commit is contained in:
Andrey Nering 2018-08-19 16:23:32 -03:00
parent a6cac2691b
commit df951a0c7c
2 changed files with 1 additions and 9 deletions

View File

@ -10,14 +10,6 @@ var (
ErrTaskfileAlreadyExists = errors.New("task: A Taskfile already exists")
)
type taskFileNotFound struct {
taskFile string
}
func (err taskFileNotFound) Error() string {
return fmt.Sprintf(`task: No task file found (is it named "%s"?). Use "task --init" to create a new one`, err.taskFile)
}
type taskNotFoundError struct {
taskName string
}

View File

@ -16,7 +16,7 @@ func Taskfile(dir string) (*taskfile.Taskfile, error) {
path := filepath.Join(dir, "Taskfile.yml")
t, err := readTaskfile(path)
if err != nil {
return nil, err
return nil, fmt.Errorf(`No Taskfile.yml found. Use "task --init" to create a new one`)
}
path = filepath.Join(dir, fmt.Sprintf("Taskfile_%s.yml", runtime.GOOS))