Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/cli/cli
/ functions
Functions
7,572 in github.com/cli/cli
⨍
Functions
7,572
◇
Types & classes
1,537
↓ 4 callers
Method
Type
()
internal/codespaces/connection/tunnels_api_server_mock.go:362
↓ 4 callers
Method
UncommittedChangeCount
(ctx context.Context)
git/client.go:340
↓ 4 callers
Method
UnwrapOr
UnwrapOr returns the underlying value of a [Some] variant, or the provided value on a [None] variant.
pkg/option/option.go:81
↓ 4 callers
Method
UnwrapOrZero
UnwrapOrZero returns the underlying value of a [Some] variant, or the zero value on a [None] variant.
pkg/option/option.go:101
↓ 4 callers
Function
UpdateProjectV2Items
UpdateProjectV2Items uses the addProjectV2ItemById and the deleteProjectV2Item mutations to add and delete items from projects. The addProjectItems an
api/queries_projects_v2.go:35
↓ 4 callers
Method
Upgrade
(name string, force bool)
pkg/extensions/extension.go:36
↓ 4 callers
Method
Warnings
Warnings returns the deduplicated warnings recorded so far in this process, such as a skipped token refresh, in the order they were first recorded. Ca
internal/gh/gh.go:235
↓ 4 callers
Function
WithEndpointScopes
WithEndpointScopes adds OAuth scopes to a 4xx error as if the server endpoint had returned them. This improves error messaging for endpoints that do n
api/client.go:93
↓ 4 callers
Function
WithoutFollowingRedirects
WithoutFollowingRedirects stops the request from following redirects. When a redirect is encountered, the request fails with an HTTPError carrying the
api/client.go:84
↓ 4 callers
Function
Write
Write colorized JSON output parsed from reader
pkg/jsoncolor/jsoncolor.go:24
↓ 4 callers
Method
activateUser
(hostname, user string)
internal/config/config.go:691
↓ 4 callers
Method
addDefaultsToPrompt
addDefaultsToPrompt adds default values to the prompt string.
internal/prompter/prompter.go:99
↓ 4 callers
Method
addWarning
addWarning records msg for Warnings unless an identical message was already recorded.
internal/config/config.go:297
↓ 4 callers
Function
appendJSONL
appendJSONL adds items to a file, one JSON object per line.
script/ghmock/store.go:224
↓ 4 callers
Method
appendMetadata
Appends the authentication token to the gRPC context
internal/codespaces/rpc/invoker.go:164
↓ 4 callers
Method
ask
(q survey.Prompt, response any, opts ...survey.AskOpt)
internal/prompter/prompter.go:578
↓ 4 callers
Function
blockRange
blockRange returns the byte range a block covers in the source.
internal/attachments/references.go:496
↓ 4 callers
Method
bodyBytes
()
script/ghmock/store.go:27
↓ 4 callers
Method
buildMultiSelectWithSearchForm
(prompt, searchPrompt string, defaultValues, persistentValues []string, searchFunc func(string) MultiSelectSea
internal/prompter/huh_prompter.go:109
↓ 4 callers
Method
check
(e loggedRequest, resp *response, validateVariables bool)
script/ghmock/checker.go:160
↓ 4 callers
Method
check
Throws if the stream has printed malformed output, including output after the review that was awaited.
evals/src/suites/events/smoke-protocol.ts:120
↓ 4 callers
Method
chooseVerifier
(issuer string)
pkg/cmd/attestation/verification/sigstore.go:206
↓ 4 callers
Method
cleanExtensionUpdateDir
cleanExtensionUpdateDir deletes the extension-specific directory containing metadata used in checking for updates. Because extension names are not uni
pkg/cmd/extension/manager.go:878
↓ 4 callers
Method
clone
()
pkg/cmd/pr/shared/editable.go:323
↓ 4 callers
Function
cloneEvent
(event ghtelemetry.Event)
internal/telemetry/telemetry.go:399
↓ 4 callers
Function
cmdRepo
(args []string, stdout io.Writer)
script/ghmock/gitcmd.go:43
↓ 4 callers
Method
collect
collect groups the fields a selection asks for on an object of type concrete by response key, in query order. Fields that share a key are merged into
script/ghmock/gqlscaffold.go:314
↓ 4 callers
Function
comparableDestination
comparableDestination reduces a destination goldmark reported to the single form used to decide whether a run of source is the node it came from. Perc
internal/attachments/references.go:442
↓ 4 callers
Function
containCommand
containCommand gives a command and its Git children one process group so cancelling a run does not leave a transport or pack process behind. A PTY cre
script/ghmock/process_unix.go:16
↓ 4 callers
Function
convertIntToUint16
convertIntToUint16 converts the given int to a uint16.
internal/codespaces/portforwarder/port_forwarder.go:415
↓ 4 callers
Function
copyGitTree
copyGitTree preserves the index, untracked files and worktree metadata, which a clone would lose. It copies file contents, never hardlinks. Only Git's
script/ghmock/gitfixture.go:123
↓ 4 callers
Function
createCommand
(t *testing.T, exitStatus int, stdout, stderr string)
git/client_test.go:1720
↓ 4 callers
Function
createRun
(opts *CreateOptions)
pkg/cmd/issue/create/create.go:200
↓ 4 callers
Function
deduplicateResults
deduplicateResults extracts unique (repo, namespace, skill name) triples from code search hits.
pkg/cmd/skills/search/search.go:780
↓ 4 callers
Function
deleteRepo
(httpClient *http.Client, repo ghrepo.Interface)
pkg/cmd/repo/delete/http.go:46
↓ 4 callers
Function
describeSchemaType
describeSchemaType names the JSON a schema allows, such as "string or null" or "object (simple-user)".
script/ghmock/schemacmd.go:438
↓ 4 callers
Function
digestContainerImageArtifact
(url string, client oci.Client)
pkg/cmd/attestation/artifact/image.go:10
↓ 4 callers
Function
down
()
internal/prompter/huh_prompter_test.go:81
↓ 4 callers
Function
downloadRun
(opts *DownloadOptions)
pkg/cmd/release/download/download.go:144
↓ 4 callers
Method
ensureGitFixture
()
script/ghmock/gitfixture.go:55
↓ 4 callers
Function
fetchLatestRelease
fetchLatestRelease finds the latest published release for a repository.
pkg/cmd/extension/http.go:113
↓ 4 callers
Function
fieldByName
(v reflect.Value, field string)
pkg/search/result.go:449
↓ 4 callers
Function
file_codespace_codespace_host_service_v1_proto_rawDescGZIP
()
internal/codespaces/rpc/codespace/codespace_host_service.v1.pb.go:290
↓ 4 callers
Function
formatValuesForUsageDocs
(values []string)
pkg/cmdutil/flags.go:68
↓ 4 callers
Function
getAttestations
(o *Options, a artifact.DigestedArtifact)
pkg/cmd/attestation/verify/attestation.go:13
↓ 4 callers
Function
getPubKey
(client *api.Client, host string, path safeurl.SafeURL)
pkg/cmd/secret/set/http.go:34
↓ 4 callers
Method
getRepositoryMeta
getRepositoryMeta fetches the node ID, database ID, and discussion-enabled flag for a repository.
pkg/cmd/discussion/client/client.go:829
↓ 4 callers
Function
getVariables
(client *http.Client, host string, u *safeurl.MutableSafeURL)
pkg/cmd/variable/list/list.go:237
↓ 4 callers
Function
ghEnv
ghEnv builds gh's whole environment from scratch, so the caller's tokens, config and git settings never reach it. Every run gets fresh directories, so
script/ghmock/run.go:525
↓ 4 callers
Function
gitEnvironment
(env []string, scratch, world string)
script/ghmock/gitcmd.go:316
↓ 4 callers
Function
gitForTest
(t *testing.T, args ...string)
script/ghmock/gitcmd_test.go:367
↓ 4 callers
Function
gitRepoPath
(world, host, repo string)
script/ghmock/gitfixture.go:44
↓ 4 callers
Function
httpResponseWithHeader
(status int, req *http.Request, body io.Reader, header http.Header)
pkg/httpmock/stub.go:274
↓ 4 callers
Function
indentProblems
indentProblems lists problems one per line. With a limit above zero, it shows at most that many and points to the log for the rest.
script/ghmock/report.go:183
↓ 4 callers
Method
infof
(format string, args ...any)
pkg/cmd/pr/merge/merge.go:559
↓ 4 callers
Function
initialize
initialize generate slices over a range for test scenarios using the provided initializer.
pkg/search/searcher_test.go:1380
↓ 4 callers
Function
isAPIHost
isAPIHost reports whether gh sends REST and GraphQL calls to hostname, for github.com or, with --localhost, for github.localhost.
script/ghmock/request.go:47
↓ 4 callers
Function
isPathRedirect
(_ *Root, _ *os.Root, _ string, info os.FileInfo)
internal/safepaths/link_other.go:7
↓ 4 callers
Function
isolatedEnvironment
(home: string, path: string, modelToken: string)
evals/src/core/io.ts:40
↓ 4 callers
Function
issueList
(client *http.Client, detector fd.Detector, repo ghrepo.Interface, filters prShared.FilterOptions, limit int)
pkg/cmd/issue/list/list.go:231
↓ 4 callers
Function
keyFor
(hostname string)
pkg/cmd/auth/shared/gitcredentials/helper_config.go:114
↓ 4 callers
Function
listPullRequests
(httpClient *http.Client, detector fd.Detector, repo ghrepo.Interface, filters prShared.FilterOptions, limit i
pkg/cmd/pr/list/http.go:17
↓ 4 callers
Function
listenRun
(ctx context.Context, opts *ListenOptions)
pkg/cmd/event/listen/listen.go:222
↓ 4 callers
Method
loadManifest
()
pkg/cmd/extension/extension.go:224
↓ 4 callers
Method
localPath
(name string)
internal/safepaths/root.go:268
↓ 4 callers
Method
log
(text: string)
evals/src/core/executor.ts:118
↓ 4 callers
Function
login
(t *testing.T, c gh.Config, hostname, username, token, gitProtocol string, secureStorage bool)
pkg/cmd/auth/token/token_test.go:488
↓ 4 callers
Function
loginRun
(opts *LoginOptions)
pkg/cmd/auth/login/login.go:201
↓ 4 callers
Function
mergeSelections
(fields []*ast.Field)
script/ghmock/gqlscaffold.go:388
↓ 4 callers
Function
newAttachableMarkdown
newAttachableMarkdown scans markdown for the files it references, and refuses references that no asset URL can fix.
internal/attachments/references.go:70
↓ 4 callers
Function
newCertAuthority
()
script/ghmock/tls.go:31
↓ 4 callers
Function
newContentWriter
newContentWriter returns the writer to wire up as ContentOut. When sanitize is true it inserts an asciisanitizer in front of the underlying writer; ot
pkg/iostreams/iostreams.go:504
↓ 4 callers
Function
newTestUploader
newTestUploader builds an uploader whose requests land in reg.
internal/attachments/client_test.go:45
↓ 4 callers
Function
nextPage
nextPage extracts the next page number from an API response's link header. if the provided link header is empty or there is no next page, zero is retu
pkg/search/searcher.go:349
↓ 4 callers
Function
object
(value: unknown)
evals/src/suites/events/grading/observations.ts:7
↓ 4 callers
Method
once
(method: string, path: string, body?: unknown)
evals/src/core/github.ts:85
↓ 4 callers
Function
parseFields
(opts *ApiOptions)
pkg/cmd/api/fields.go:16
↓ 4 callers
Function
parseGitRepo
(name string)
script/ghmock/gitfixture.go:26
↓ 4 callers
Function
parseJournal
(value: unknown)
evals/src/core/sandbox.ts:35
↓ 4 callers
Method
path
path returns where an artifact's file goes: in Dir under its file name, or at Output. Like gh repo read-file --output, an existing directory, or a pat
pkg/cmd/issue/artifact/download/download.go:358
↓ 4 callers
Function
plural
(n int, noun string)
script/ghmock/report.go:271
↓ 4 callers
Function
prFromFixtures
hack for compatibility with old JSON fixture files
pkg/cmd/pr/view/view_test.go:213
↓ 4 callers
Function
processExitCode
(err error)
script/ghmock/gittransport.go:237
↓ 4 callers
Method
proxyURL
proxyURL is the value gh gets for HTTP_PROXY and HTTPS_PROXY.
script/ghmock/server.go:90
↓ 4 callers
Function
publishRun
(opts *PublishOptions)
pkg/cmd/skills/publish/publish.go:169
↓ 4 callers
Method
pull
(repo: string, number: number)
evals/src/core/github.ts:109
↓ 4 callers
Function
putSecret
(client *api.Client, host string, path safeurl.SafeURL, payload any)
pkg/cmd/secret/set/http.go:75
↓ 4 callers
Method
qualifiedName
qualifiedName returns the namespace-qualified skill name (e.g. "author/skill") or just the skill name if there is no namespace.
pkg/cmd/skills/search/search.go:178
↓ 4 callers
Function
quote
(s string)
pkg/search/query.go:286
↓ 4 callers
Function
rawBodySummary
(body []byte)
script/ghmock/log.go:151
↓ 4 callers
Method
readmeWidth
()
pkg/cmd/extension/browse/model.go:572
↓ 4 callers
Method
record
(e loggedRequest)
script/ghmock/server.go:121
↓ 4 callers
Function
recordCommandArgs
(t *testing.T, gotArgs *[]string)
git/client_test.go:1734
↓ 4 callers
Method
replace
(handle string)
pkg/cmd/pr/shared/params.go:354
↓ 4 callers
Function
repoCreate
repoCreate creates a new GitHub repository
pkg/cmd/repo/create/http.go:77
↓ 4 callers
Function
repoMetaResp
(id string, discussionsEnabled bool)
pkg/cmd/discussion/client/client_test.go:2343
↓ 4 callers
Function
requireKeyWithValue
(t *testing.T, cfg *config.Config, keys []string, value string)
internal/config/migration/multi_account_test.go:234
↓ 4 callers
Function
requiresUserCapabilityForScript
(file string)
acceptance/user_capability_test.go:43
↓ 4 callers
Function
resolveEnterpriseVersion
(httpClient *http.Client, host string)
internal/featuredetection/feature_detection.go:661
↓ 4 callers
Function
retryAfter
retryAfter returns the delay requested by the Retry-After header of an HTTP error, or zero. The header holds either a number of seconds or an HTTP dat
pkg/cmd/event/listen/listen.go:532
← previous
next →
801–900 of 7,572, ranked by callers