fix: globals vars are available in vars at root level (#2403)

This commit is contained in:
Valentin Maerten
2025-12-12 21:20:27 +01:00
committed by GitHub
parent 85a98b5f90
commit 5889ff6b65
2 changed files with 31 additions and 3 deletions

View File

@@ -166,8 +166,7 @@ func run() error {
globals.Set("CLI_SILENT", ast.Var{Value: flags.Silent})
globals.Set("CLI_VERBOSE", ast.Var{Value: flags.Verbose})
globals.Set("CLI_OFFLINE", ast.Var{Value: flags.Offline})
e.Taskfile.Vars.Merge(globals, nil)
e.Taskfile.Vars.ReverseMerge(globals, nil)
if !flags.Watch {
e.InterceptInterruptSignals()
}