MCPcopy Create free account
hub / github.com/cli/cli / patchRepoVariable

Function patchRepoVariable

pkg/cmd/variable/set/http.go:167–176  ·  view source on GitHub ↗
(client *api.Client, repo ghrepo.Interface, variableName, value string)

Source from the content-addressed store, hash-verified

165}
166
167func patchRepoVariable(client *api.Client, repo ghrepo.Interface, variableName, value string) error {
168 payload := setPayload{
169 Value: value,
170 }
171 path, err := safeurl.JoinPath("repos", repo.RepoOwner(), repo.RepoName(), "actions", "variables", variableName)
172 if err != nil {
173 return err
174 }
175 return patchVariable(client, repo.RepoHost(), path, payload)
176}

Callers 1

setVariableFunction · 0.85

Calls 5

JoinPathFunction · 0.92
patchVariableFunction · 0.85
RepoOwnerMethod · 0.65
RepoNameMethod · 0.65
RepoHostMethod · 0.65

Tested by

no test coverage detected