code: func ValidateProjectName(p string) error {
  	if len(p) == 0 {
  		return errors.New("cannot have empty name")
  	}
  
  	for idx, r := range p {
  		switch {
  		case r >= 'a' && r <= 'z':
  
  		case (r >= '0' && r <= '9'), r == '-', r == '_':
  			if idx == 0 {
  				return errors.New("must begin with a letter")
  			}
  
  		default:
  			return fmt.Errorf("invalid character at %d (%c)", idx, r)
  		}
  	}
  
  	return nil
  }
docs: // ValidateProjectName returns an error if the supplied string is not a valid
  // project name.
  //
  // A valid project name may only include:
  //	- Lowercase letters [a-z]
  //	- Numbers [0-9]
  //	- Hyphen (-)
  //	- Underscore (_)
  //
  // It also must begin with a letter.
  //
  // See:
  // https://github.com/luci/luci-py/blob/8e594074929871a9761d27e814541bc0d7d84744/appengine/components/components/config/common.py#L41