MCPcopy
hub / github.com/cli/cli / getEnvVariables

Function getEnvVariables

pkg/cmd/variable/list/list.go:199–202  ·  view source on GitHub ↗
(client *http.Client, repo ghrepo.Interface, envName string)

Source from the content-addressed store, hash-verified

197}
198
199func getEnvVariables(client *http.Client, repo ghrepo.Interface, envName string) ([]shared.Variable, error) {
200 path := fmt.Sprintf("repos/%s/environments/%s/variables", ghrepo.FullName(repo), envName)
201 return getVariables(client, repo.RepoHost(), path)
202}
203
204func getOrgVariables(client *http.Client, host, orgName string, showSelectedRepoInfo bool) ([]shared.Variable, error) {
205 variables, err := getVariables(client, host, fmt.Sprintf("orgs/%s/actions/variables", orgName))

Callers 1

listRunFunction · 0.85

Calls 3

FullNameFunction · 0.92
getVariablesFunction · 0.85
RepoHostMethod · 0.65

Tested by

no test coverage detected