code: func (it *Iterator) ForEach(c context.Context, cfg *Config, cb func(context.Context, *Env) error) error {
  	return iterDir(c, cfg.BaseDir, func(fileInfos []os.FileInfo) error {
  		if it.Shuffle {
  			for i := range fileInfos {
  				j := mathrand.Intn(c, i+1)
  				fileInfos[i], fileInfos[j] = fileInfos[j], fileInfos[i]
  			}
  		}
  
  		for _, fi := range fileInfos {
  			// Ignore hidden files.
  			if !fi.IsDir() || strings.HasPrefix(fi.Name(), ".") {
  				continue
  			}
  
  			e := cfg.envForName(fi.Name(), nil)
  			if it.OnlyComplete {
  				if err := e.AssertCompleteAndLoad(); err != nil {
  					logging.WithError(err).Debugf(c, "Skipping VirtualEnv %s; not complete.", fi.Name())
  					continue
  				}
  			}
  
  			if err := cb(c, e); err != nil {
  				return err
  			}
  		}
  
  		return nil
  	})
  }
docs: // ForEach iterates over all VirtualEnv installations for the supplied "cfg".
  //
  // "cb" will be invoked for each VirtualEnv, regardless of its completion
  // status. The callback may perform additional operations on the VirtualEnv to
  // determine its actual status. If the callback returns an error, iteration will
  // stop and the error will be forwarded.
  //
  // If the supplied Context is cancelled, iteration will stop prematurely and
  // return the Context's error.