code: func Reindex(ch *chart.Chart, path string) error {
  	name := ch.Metadata.Name + "-" + ch.Metadata.Version
  	y, err := LoadIndexFile(path)
  	if err != nil {
  		return err
  	}
  	found := false
  	for k := range y.Entries {
  		if k == name {
  			found = true
  			break
  		}
  	}
  	if !found {
  		dig, err := provenance.DigestFile(path)
  		if err != nil {
  			return err
  		}
  
  		y.Add(ch.Metadata, name+".tgz", "http://127.0.0.1:8879/charts", "sha256:"+dig)
  
  		out, err := yaml.Marshal(y)
  		if err != nil {
  			return err
  		}
  
  		ioutil.WriteFile(path, out, 0644)
  	}
  	return nil
  }
docs: // Reindex adds an entry to the index file at the given path