MCPcopy Index your code
hub / github.com/cli/cli / v1ProjectNameToID

Method v1ProjectNameToID

api/queries_repo.go:847–855  ·  view source on GitHub ↗

We use the word "titles" when referring to v1 and v2 projects. In reality, v1 projects really have "names", so there is a bit of a mismatch we just need to gloss over.

(name string)

Source from the content-addressed store, hash-verified

845// In reality, v1 projects really have "names", so there is a bit of a
846// mismatch we just need to gloss over.
847func (m *RepoMetadataResult) v1ProjectNameToID(name string) (string, bool) {
848 for _, p := range m.Projects {
849 if strings.EqualFold(name, p.Name) {
850 return p.ID, true
851 }
852 }
853
854 return "", false
855}
856
857func (m *RepoMetadataResult) v2ProjectTitleToID(title string) (string, bool) {
858 for _, p := range m.ProjectsV2 {

Callers 1

ProjectsTitlesToIDsMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected