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

v3: Do not include Taskfile_{{OS}}.yml automatically

This commit is contained in:
Andrey Nering
2020-05-17 15:42:27 -03:00
parent 6a604b3002
commit 191c34c9c4
4 changed files with 30 additions and 19 deletions

11
task.go
View File

@ -6,7 +6,6 @@ import (
"fmt"
"io"
"os"
"strconv"
"sync"
"sync/atomic"
@ -112,7 +111,7 @@ func (e *Executor) Setup() error {
return err
}
v, err := e.parsedVersion()
v, err := e.Taskfile.ParsedVersion()
if err != nil {
return err
}
@ -246,14 +245,6 @@ func (e *Executor) Setup() error {
return nil
}
func (e *Executor) parsedVersion() (float64, error) {
v, err := strconv.ParseFloat(e.Taskfile.Version, 64)
if err != nil {
return 0, fmt.Errorf(`task: Could not parse taskfile version "%s": %v`, e.Taskfile.Version, err)
}
return v, nil
}
// RunTask runs a task by its name
func (e *Executor) RunTask(ctx context.Context, call taskfile.Call) error {
t, err := e.CompiledTask(call)