code: func (d *DotGit) RemoveRef(name plumbing.ReferenceName) error {
  	path := d.fs.Join(".", name.String())
  	_, err := d.fs.Stat(path)
  	if err == nil {
  		err = d.fs.Remove(path)
  		// Drop down to remove it from the packed refs file, too.
  	}
  
  	if err != nil && !os.IsNotExist(err) {
  		return err
  	}
  
  	return d.rewritePackedRefsWithoutRef(name)
  }
docs: // RemoveRef removes a reference by name.