MCPcopy Create free account
hub / github.com/github/gh-aw / getRepositorySlugFromRemotePreferringUpstream

Function getRepositorySlugFromRemotePreferringUpstream

pkg/cli/git.go:238–240  ·  view source on GitHub ↗

getRepositorySlugFromRemotePreferringUpstream extracts the repository slug (owner/repo) from git remotes, preferring the 'upstream' remote when available. This keeps schedule scattering stable for fork checkouts where origin points to the fork.

()

Source from the content-addressed store, hash-verified

236// from git remotes, preferring the 'upstream' remote when available.
237// This keeps schedule scattering stable for fork checkouts where origin points to the fork.
238func getRepositorySlugFromRemotePreferringUpstream() string {
239 return getRepositorySlugFromDirPreferringUpstream("")
240}
241
242// getRepositorySlugFromDirPreferringUpstream extracts the repository slug (owner/repo)
243// for a git working directory, preferring the 'upstream' remote when available.