pkg/task/task.go
func RunAnnotated(task Task, description string, symbol string, options ...interface{}) error {
	doneCh := make(chan bool)
	errCh := make(chan error)

	l := logger.Log
	t := DefaultTicker

	for _, o := range options {
		if value, ok := o.(logger.Logger); ok {
			l = value
		} else if value, ok := o.(*time.Ticker); ok {
			t = value
		}
	}

	go func() {
		errCh <- task()
	}()

	l(description)
	logActivity(symbol, l, t, doneCh)

	err := <-errCh
	doneCh <- true

	return err
}
func RunAnnotated(task Task, description string, symbol string, options ...interface{}) error {
	doneCh := make(chan bool)
	errCh := make(chan error)

	l := logger.Log
	t := DefaultTicker

	for _, o := range options {
		if value, ok := o.(logger.Logger); ok {
			l = value
		} else if value, ok := o.(*time.Ticker); ok {
			t = value
		}
	}

	go func() {
		errCh <- task()
	}()

	l(description)
	logActivity(symbol, l, t, doneCh)

	err := <-errCh
	doneCh <- true

	return err
}
// RunAnnotated annotates a task with a description and a sequence of symbols indicating task activity until it terminates