MCPcopy Index your code
hub / github.com/go-task/task / setupConcurrencyState

Method setupConcurrencyState

setup.go:263–276  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

261}
262
263func (e *Executor) setupConcurrencyState() {
264 e.executionHashes = make(map[string]context.Context)
265
266 e.taskCallCount = make(map[string]*int32, e.Taskfile.Tasks.Len())
267 e.mkdirMutexMap = make(map[string]*sync.Mutex, e.Taskfile.Tasks.Len())
268 for k := range e.Taskfile.Tasks.Keys(nil) {
269 e.taskCallCount[k] = new(int32)
270 e.mkdirMutexMap[k] = &sync.Mutex{}
271 }
272
273 if e.Concurrency > 0 {
274 e.concurrencySemaphore = make(chan struct{}, e.Concurrency)
275 }
276}
277
278func (e *Executor) doVersionChecks() error {
279 if !e.EnableVersionCheck {

Callers 1

SetupMethod · 0.95

Calls 2

LenMethod · 0.45
KeysMethod · 0.45

Tested by

no test coverage detected