Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/go-task/task
/ functions
Functions
992 in github.com/go-task/task
⨍
Functions
992
◇
Types & classes
215
↓ 143 callers
Method
String
()
taskfile/snippet.go:140
↓ 109 callers
Method
Run
Run runs Task
task.go:42
↓ 85 callers
Function
WithExecutorOptions
WithExecutorOptions sets the [task.ExecutorOption]s to be used when creating a [task.Executor].
task_test.go:185
↓ 80 callers
Function
NewExecutorTest
NewExecutorTest sets up a new [task.Executor] with the given options and runs a task with the given [ExecutorTestOption]s. The output of the task is w
executor_test.go:46
↓ 77 callers
Function
SmartJoin
SmartJoin joins two paths, but only if the second is not already an absolute path.
internal/filepathext/filepathext.go:11
↓ 73 callers
Function
WithName
Functional options WithName gives the test fixture output a name. This should be used when running multiple tests in a single test function.
task_test.go:130
↓ 72 callers
Method
Setup
()
setup.go:26
↓ 67 callers
Method
Run
(t *testing.T)
task_test.go:408
↓ 67 callers
Function
WithTask
WithTask sets the name of the task to run. This should be used when the task to run is not the default task.
task_test.go:148
↓ 63 callers
Function
NewTaskfileDecodeError
(err error, node *yaml.Node)
errors/error_taskfile_decode.go:26
↓ 53 callers
Method
Error
()
errors/errors_task.go:41
↓ 45 callers
Method
Outf
Outf prints stuff to STDOUT.
internal/logger/logger.go:143
↓ 45 callers
Method
Set
Set sets the value of the variable with the provided key to the provided value. If the variable already exists, its value is updated. If the variable
taskfile/ast/vars.go:62
↓ 36 callers
Function
NewVars
NewVars creates a new instance of Vars and initializes it with the provided set of elements, if any. The elements are added in the order they are pass
taskfile/ast/vars.go:27
↓ 31 callers
Method
Get
Get returns the value the the variable with the provided key and a boolean that indicates if the value was found or not. If the value is not found, th
taskfile/ast/vars.go:50
↓ 28 callers
Function
Replace
(v T, cache *Cache)
internal/templater/templater.go:61
↓ 27 callers
Method
DeepCopy
()
internal/deepcopy/deepcopy.go:10
↓ 26 callers
Method
All
All returns an iterator that loops over all task key-value pairs.
taskfile/ast/vars.go:75
↓ 25 callers
Method
Location
()
taskfile/node.go:19
↓ 24 callers
Method
Len
Len returns the number of variables in the Vars map.
taskfile/ast/vars.go:38
↓ 23 callers
Method
Dir
()
taskfile/node.go:20
↓ 23 callers
Function
New
New returns an error that formats as the given text. Each call to New returns a distinct error value even if the text is identical. This wraps the sta
errors/errors.go:55
↓ 23 callers
Function
getConfig
getConfig extracts a config value with priority: env var > taskrc config > fallback
internal/flags/flags.go:318
↓ 21 callers
Method
Return
(s string)
internal/fingerprint/checker_mock.go:211
↓ 21 callers
Method
Run
(run func())
internal/fingerprint/checker_mock.go:204
↓ 21 callers
Function
WithColumn
WithColumn specifies the column number that the [Snippet] should point to.
taskfile/snippet.go:102
↓ 21 callers
Function
WithRunError
WithRunError tells the test to expect an error during the run phase of the task execution. A fixture will be created with the output of any errors.
executor_test.go:93
↓ 20 callers
Method
Err
()
internal/templater/templater.go:30
↓ 20 callers
Method
Errf
Errf prints stuff to STDERR.
internal/logger/logger.go:167
↓ 20 callers
Function
Slice
(orig []T)
internal/deepcopy/deepcopy.go:22
↓ 20 callers
Function
WithLine
WithLine specifies the line number that the [Snippet] should center around and point to.
taskfile/snippet.go:89
↓ 19 callers
Function
NewGitNode
( entrypoint string, dir string, insecure bool, opts ...NodeOption, )
taskfile/node_git.go:61
↓ 19 callers
Method
WithTypeMessage
(t string)
errors/error_taskfile_decode.go:118
↓ 17 callers
Method
Name
()
taskfile/ast/task.go:56
↓ 16 callers
Function
Globs
(dir string, globs []*ast.Glob, useGitignore bool)
internal/fingerprint/glob.go:13
↓ 15 callers
Function
writeFile
(t *testing.T, dir, filename, content string)
taskrc/taskrc_test.go:53
↓ 14 callers
Method
Error
()
taskfile/ast/platforms.go:33
↓ 14 callers
Method
IsUpToDate
(ctx context.Context, t *ast.Task)
internal/fingerprint/checker.go:11
↓ 14 callers
Method
repoCacheKey
repoCacheKey generates a unique cache key for the repository+ref combination. Unlike CacheKey() which includes the file path, this identifies the repo
taskfile/node_git.go:235
↓ 13 callers
Function
GetConfig
GetConfig loads and merges local and global Task configuration files
taskrc/taskrc.go:26
↓ 13 callers
Function
Is
Is wraps the standard errors.Is function so that we don't need to alias that package.
errors/errors.go:60
↓ 13 callers
Function
WithVar
WithVar sets a variable to be passed to the task. This can be called multiple times to set more than one variable.
task_test.go:166
↓ 13 callers
Function
envColor
(name string, defaultColor color.Attribute)
internal/logger/logger.go:103
↓ 12 callers
Method
Close
()
internal/execext/devnull.go:13
↓ 12 callers
Method
EXPECT
()
internal/fingerprint/checker_mock.go:37
↓ 12 callers
Function
ReplaceWithExtra
(v T, cache *Cache, extra map[string]any)
internal/templater/templater.go:65
↓ 12 callers
Method
VerboseErrf
VerboseErrf prints stuff to STDERR if verbose mode is enabled.
internal/logger/logger.go:179
↓ 11 callers
Function
PrintTask
(l *logger.Logger, t *ast.Task)
internal/summary/summary.go:31
↓ 11 callers
Function
buildHTTPClient
buildHTTPClient creates an HTTP client with optional TLS configuration. If no certificate options are provided, it returns http.DefaultClient.
taskfile/node_http.go:29
↓ 10 callers
Method
FOutf
FOutf prints stuff to the given writer.
internal/logger/logger.go:148
↓ 10 callers
Function
WithPadding
WithPadding specifies the number of lines to include before and after the selected line in the [Snippet].
taskfile/snippet.go:116
↓ 10 callers
Method
debugf
(format string, a ...any)
taskfile/reader.go:262
↓ 9 callers
Function
ExpandLiteral
ExpandLiteral is a wrapper around [expand.Literal]. It will escape the input string, expand any shell symbols (such as '~') and resolve any environmen
internal/execext/exec.go:105
↓ 9 callers
Function
GetTaskEnv
(key string)
internal/env/env.go:63
↓ 9 callers
Method
ToCacheMap
ToCacheMap converts Vars to an unordered map containing only the static variables
taskfile/ast/vars.go:100
↓ 9 callers
Method
WithMessage
(format string, a ...any)
errors/error_taskfile_decode.go:113
↓ 9 callers
Method
WrapWriter
(stdOut, stdErr io.Writer, prefix string, cache *templater.Cache)
internal/output/output.go:13
↓ 9 callers
Function
setupDirs
(t *testing.T)
taskrc/taskrc_test.go:35
↓ 8 callers
Method
VerboseOutf
VerboseOutf prints stuff to STDOUT if verbose mode is enabled.
internal/logger/logger.go:160
↓ 8 callers
Function
createDummyLogger
()
internal/summary/summary_test.go:32
↓ 7 callers
Method
Enabled
()
experiments/experiment.go:38
↓ 7 callers
Function
IsAbs
(path string)
internal/filepathext/filepathext.go:18
↓ 7 callers
Method
ShouldUseGitignore
ShouldUseGitignore returns true if gitignore filtering is enabled for the task. Returns false if UseGitignore is nil or set to false.
taskfile/ast/task.go:81
↓ 7 callers
Function
WithFixtureTemplating
WithFixtureTemplating enables templating for the golden fixture files with the default set of data. This is useful if the golden file is dynamic in so
task_test.go:260
↓ 7 callers
Function
WithPostProcessFn
WithPostProcessFn adds a [PostProcessFn] function to the test. Post-process functions are run on the output of the task before a fixture is created. T
task_test.go:224
↓ 7 callers
Function
asAnySlice
(slice []T)
variables.go:349
↓ 7 callers
Function
getScheme
(uri string)
taskfile/node.go:87
↓ 7 callers
Function
initGitRepo
(t *testing.T, dir string)
internal/fingerprint/gitignore_test.go:15
↓ 6 callers
Function
Convert
(s []T, f func(T) U)
internal/slicesext/slicesext.go:22
↓ 6 callers
Method
GetTask
GetTask will return the task with the name matching the given call from the taskfile. If no task is found, it will search for tasks with a matching al
task.go:523
↓ 6 callers
Method
Match
Match matches patterns in the order of priorities. As soon as an inclusion or exclusion is found, not further matching is performed.
internal/gitignore/matcher.go:11
↓ 6 callers
Method
Merge
Merge loops over other and merges it values with the variables in vars. If the include parameter is not nil and its it is an advanced import, the dire
taskfile/ast/vars.go:125
↓ 6 callers
Function
New
New creates a new experiment with the given name and sets the values that can enable it.
experiments/experiment.go:19
↓ 6 callers
Function
RunCommand
RunCommand runs a shell command
internal/execext/exec.go:35
↓ 6 callers
Method
RunTask
RunTask runs a task by its name
task.go:128
↓ 6 callers
Function
Scalar
(orig *T)
internal/deepcopy/deepcopy.go:13
↓ 6 callers
Method
Set
Set sets the value of the task with the provided key to the provided value. If the task already exists, its value is updated. If the task does not exi
taskfile/ast/tasks.go:66
↓ 6 callers
Function
normalizePathSeparators
normalizePathSeparators converts backslashes to forward slashes for cross-platform path comparison.
task_test.go:326
↓ 6 callers
Function
run
()
cmd/task/task.go:60
↓ 6 callers
Function
taskNameWithNamespace
(taskName string, namespace string)
taskfile/ast/tasks.go:246
↓ 6 callers
Method
writeFixtureBuffer
writeFixtureBuffer is a wrapper for writing the main output of the task to a fixture file.
task_test.go:106
↓ 5 callers
Function
As
As wraps the standard errors.As function so that we don't need to alias that package.
errors/errors.go:65
↓ 5 callers
Function
Get
(t *ast.Task)
internal/env/env.go:28
↓ 5 callers
Function
IsRemoteEntrypoint
(entrypoint string)
taskfile/node.go:77
↓ 5 callers
Method
Location
()
taskfile/node_git.go:93
↓ 5 callers
Function
NewFormatterTest
NewFormatterTest sets up a new [task.Executor] with the given options and runs a task with the given [FormatterTestOption]s. The output of the task is
formatter_test.go:41
↓ 5 callers
Function
NewTasks
NewTasks creates a new instance of Tasks and initializes it with the provided set of elements, if any. The elements are added in the order they are pa
taskfile/ast/tasks.go:31
↓ 5 callers
Function
ReplaceVars
(vars *ast.Vars, cache *Cache)
internal/templater/templater.go:147
↓ 5 callers
Method
ResolveEntrypoint
(entrypoint string)
taskfile/node_git.go:189
↓ 5 callers
Function
SearchPath
SearchPath will check if a file at the given path exists or not. If it does, it will return the path to it. If it does not, it will search for any fil
internal/fsext/fs.go:122
↓ 5 callers
Method
String
()
errors/errors_task.go:161
↓ 5 callers
Method
Values
Values returns an iterator that loops over all task values.
taskfile/ast/vars.go:91
↓ 5 callers
Function
WithListOptions
Functional options WithListOptions sets the list options for the formatter.
formatter_test.go:73
↓ 5 callers
Method
run
(t *testing.T)
task_test.go:681
↓ 5 callers
Method
writeFixture
writeFixture writes a fixture file for the test. The fixture file is created using the [goldie.Goldie] package. The fixture file is created with the o
task_test.go:69
↓ 4 callers
Method
CompiledTask
CompiledTask returns a copy of a task, but replacing variables in almost all properties using the Go template package.
variables.go:34
↓ 4 callers
Method
FastCompiledTask
FastCompiledTask is like CompiledTask, but it skippes dynamic variables.
variables.go:39
↓ 4 callers
Method
Get
Get returns the value the the task with the provided key and a boolean that indicates if the value was found or not. If the value is not found, the re
taskfile/ast/tasks.go:54
↓ 4 callers
Function
IsTaskUpToDate
( ctx context.Context, t *ast.Task, opts ...CheckerOption, )
internal/fingerprint/task.go:58
↓ 4 callers
Method
ListTasks
ListTasks prints a list of tasks. Tasks that match the given filters will be excluded from the list. The function returns a boolean indicating whether
help.go:62
next →
1–100 of 992, ranked by callers