Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/anthropics/claude-code
/ functions
Functions
532 in github.com/anthropics/claude-code
⨍
Functions
532
◇
Types & classes
24
↓ 1 callers
Function
emptyOf
(data: Git.DiffData | null, filesCount: number)
mods/diff/tests/pane-state/empty-state-of.test.ts:26
↓ 1 callers
Function
extractDuplicateIssueNumber
(commentBody: string)
scripts/auto-close-duplicates.ts:49
↓ 1 callers
Function
extract_content_from_input
Extract content to check from tool input based on tool type.
plugins/security-guidance/hooks/security_reminder_hook.py:429
↓ 1 callers
Function
fetchBodies
( engine: Host, pinned: Backend.Backend, data: Git.DiffData, )
mods/diff/hooks/register.ts:221
↓ 1 callers
Function
fetchDiff
( deps: Types.GitDeps, mode: Types.BaseMode, )
mods/diff/hooks/git/fetch-diff/fetch-diff.ts:16
↓ 1 callers
Function
fetchFileHunks
( run: Types.GitRun, data: Types.DiffData, file: Types.FileStat, )
mods/diff/hooks/git/fetch-file-hunks/fetch-file-hunks.ts:21
↓ 1 callers
Function
fetched
()
mods/diff/hooks/register.ts:298
↓ 1 callers
Function
fieldsOf
(event: string, props: Fields['props'])
mods/telemetry/hooks/entries/fields-of/fields-of.ts:13
↓ 1 callers
Function
fileEditOf
(result: unknown)
mods/diff/hooks/turns/turn-of/file-edit-of/file-edit-of.ts:16
↓ 1 callers
Function
fileOf
(entry: Entries.BodyEntry)
mods/diff/hooks/views/body/plan/segments/segments-of.ts:76
↓ 1 callers
Function
filter_preexisting_from_diff
Filter out pre-existing content from diff files. When a file is fully rewritten (Write tool replaces entire content), git shows all lines
plugins/security-guidance/hooks/gitutil.py:657
↓ 1 callers
Function
firstLineCut
(hunk: Git.Hunk, maxChars: number)
mods/diff/hooks/views/detail/sub-hunks-of/first-line-cut/first-line-cut.ts:12
↓ 1 callers
Function
get_baseline_file_content
Get the content of a file at the baseline SHA. Returns None if unavailable.
plugins/security-guidance/hooks/diffstate.py:140
↓ 1 callers
Function
get_git_diff
Get the git diff between the baseline SHA and the current working tree, including untracked (new) files. Uses a temporary copy of the gi
plugins/security-guidance/hooks/gitutil.py:391
↓ 1 callers
Function
get_lock_file
Get session-specific lock file path.
plugins/security-guidance/hooks/session_state.py:43
↓ 1 callers
Function
gitIn
( argv: readonly string[], script: Readonly<Record<string, string>> = REPOSITORY, )
mods/diff/tests/fixtures/git-in.ts:17
↓ 1 callers
Function
gutterOf
(hunk: Git.Hunk)
mods/diff/hooks/views/body/plan/segments/segments-of.ts:33
↓ 1 callers
Function
handle_commit_review_posttooluse
PostToolUse handler for Bash — reviews git commits for security issues. Runs as asyncRewake: detects `git commit` in the Bash command, parses
plugins/security-guidance/hooks/security_reminder_hook.py:901
↓ 1 callers
Function
handle_push_sweep_posttooluse
Review the just-pushed range as one diff, advancing the base past the contiguous prefix of already-per-commit-reviewed shas. Spec: review `gi
plugins/security-guidance/hooks/security_reminder_hook.py:1378
↓ 1 callers
Function
handle_stop_hook
Handle the Stop hook — final security check using git diff. Diffs against the baseline SHA captured at UserPromptSubmit to review only co
plugins/security-guidance/hooks/security_reminder_hook.py:1700
↓ 1 callers
Function
handle_user_prompt_submit
Handle UserPromptSubmit — capture git baseline SHA. Called on every user prompt. Updates the baseline so the stop hook only reviews chang
plugins/security-guidance/hooks/security_reminder_hook.py:446
↓ 1 callers
Function
hasRemoteRef
(branch: string)
mods/diff/hooks/git/probes/default-branch-of/default-branch-of.ts:15
↓ 1 callers
Function
hintOf
(path: string)
mods/diff/tests/views/pane-view.test.ts:332
↓ 1 callers
Function
hunkOf
( starts: Record<string, string> | undefined, lines: readonly string[], )
mods/diff/hooks/git/hunk-of/hunk-of.ts:10
↓ 1 callers
Function
hunkOf
(entry: Entries.BodyEntry, hunk: Git.Hunk)
mods/diff/hooks/views/body/plan/segments/segments-of.ts:42
↓ 1 callers
Function
hunkSourceOf
(hunk: Git.Hunk)
mods/diff/hooks/views/detail/hunk-source-of/hunk-source-of.ts:10
↓ 1 callers
Function
hunksOf
(patch: unknown)
mods/diff/hooks/turns/turn-of/file-edit-of/hunks-of/hunks-of.ts:12
↓ 1 callers
Function
insetOf
(kit: Kit)
mods/diff/hooks/views/inset-of/inset-of.ts:11
↓ 1 callers
Function
isAnalyticsOff
(environment: Environment)
mods/telemetry/hooks/is-analytics-off/is-analytics-off.ts:16
↓ 1 callers
Function
isEnvSet
(value: string | undefined)
mods/telemetry/hooks/is-analytics-off/is-env-set/is-env-set.ts:8
↓ 1 callers
Function
isEnvTruthy
(value: string | undefined)
mods/telemetry/hooks/is-analytics-off/is-env-truthy/is-env-truthy.ts:8
↓ 1 callers
Function
isGeneratedFile
(path: string)
mods/diff/hooks/classify/is-generated-file/is-generated-file.ts:15
↓ 1 callers
Function
isLastOfDiff
( data: Types.DiffData, file: Types.FileStat, )
mods/diff/hooks/git/fetch-file-hunks/is-last-of-diff/is-last-of-diff.ts:14
↓ 1 callers
Function
isMarkKind
(value: unknown)
mods/telemetry/hooks/entries/is-mark-kind/is-mark-kind.ts:10
↓ 1 callers
Function
isOrgTool
(policy: Settings, tool: string)
mods/sec-default/hooks/policy/managed-tools-restored/is-org-tool/is-org-tool.ts:13
↓ 1 callers
Function
isPastDetails
(result: Types.NumstatResult)
mods/diff/hooks/git/tiers/is-past-details/is-past-details.ts:11
↓ 1 callers
Function
isPreSessionOf
(path: string, dating: Types.Dating | undefined)
mods/diff/hooks/git/probes/untracked-rows-of/untracked-rows-of.ts:28
↓ 1 callers
Function
isSafeRefName
(ref: string)
mods/diff/hooks/git/probes/is-safe-ref-name/is-safe-ref-name.ts:12
↓ 1 callers
Function
isTaken
()
mods/diff/hooks/register.ts:419
↓ 1 callers
Function
isTestFile
(path: string)
mods/diff/hooks/classify/is-test-file/is-test-file.ts:13
↓ 1 callers
Function
isUnderUtf8Ceiling
(text: string, ceiling: number)
mods/diff/hooks/git/parse/is-whole-listing/is-under-utf8-ceiling/is-under-utf8-ceiling.ts:11
↓ 1 callers
Function
isWholeListing
(stdout: string, terminator = '\0')
mods/diff/hooks/git/parse/is-whole-listing/is-whole-listing.ts:16
↓ 1 callers
Function
is_commit_review_enabled
Gate for the commit-review PostToolUse[Bash] hook. Commit review is enabled by default; ENABLE_COMMIT_REVIEW=0 remains the unconditional kill
plugins/security-guidance/hooks/security_reminder_hook.py:815
↓ 1 callers
Function
is_push_sweep_enabled
Gate for the push-sweep PostToolUse[Bash] hook. Enabled by default. ENABLE_COMMIT_REVIEW=0 remains the unconditional kill switch (push-sweep
plugins/security-guidance/hooks/security_reminder_hook.py:698
↓ 1 callers
Function
keeping
()
mods/diff/tests/fixtures/keeping.ts:7
↓ 1 callers
Function
kindWalkOf
( entryKindsOf: Types.GitDeps['entryKindsOf'], root: string, budget: number, )
mods/diff/hooks/git/probes/kind-walk-of/kind-walk-of.ts:16
↓ 1 callers
Function
labelOf
( mode: Git.BaseMode, requestedMode: Git.BaseMode, data: Git.DiffData | null, )
mods/diff/tests/pane-state/mode-label-of.test.ts:25
↓ 1 callers
Function
leadOf
(prop: string)
mods/diff/tests/fixtures/tree/text-of.ts:23
↓ 1 callers
Function
left
()
mods/diff/hooks/views/detail/code-blocks-of/code-blocks-of.ts:31
↓ 1 callers
Function
listOf
()
mods/diff/hooks/views/sidebar-pane/sidebar-pane.tsx:82
↓ 1 callers
Function
listingOf
(directory: string)
mods/diff/hooks/git/probes/kind-walk-of/kind-walk-of.ts:26
↓ 1 callers
Function
load_baseline_sha
Load the git baseline SHA from state.
plugins/security-guidance/hooks/diffstate.py:50
↓ 1 callers
Function
load_rule_file
Load a single rule file. Returns: Rule object or None if file is invalid.
plugins/hookify/core/config_loader.py:244
↓ 1 callers
Function
load_state
Load the full state dict from file.
plugins/security-guidance/hooks/session_state.py:88
↓ 1 callers
Function
loadingOf
()
mods/diff/hooks/views/prelude-of/prelude-of.tsx:36
↓ 1 callers
Function
main
Run the bootstrap. Returns (outcome, err_phase, err_kind). err_phase / err_kind are non-empty only on BUILD_FAILED — they let telemetry split
plugins/security-guidance/hooks/ensure_agent_sdk.py:57
↓ 1 callers
Function
main
Main hook function.
plugins/security-guidance/hooks/security_reminder_hook.py:2019
↓ 1 callers
Function
main
Main entry point for PostToolUse hook.
plugins/hookify/hooks/posttooluse.py:30
↓ 1 callers
Function
main
Main entry point for PreToolUse hook.
plugins/hookify/hooks/pretooluse.py:35
↓ 1 callers
Function
main
Main entry point for UserPromptSubmit hook.
plugins/hookify/hooks/userpromptsubmit.py:30
↓ 1 callers
Function
main
Main entry point for Stop hook.
plugins/hookify/hooks/stop.py:30
↓ 1 callers
Function
main
()
examples/hooks/bash_command_validator_example.py:56
↓ 1 callers
Function
mapLimited
( items: readonly T[], limit: number, fn: (item: T) => Promise<R>, )
mods/diff/hooks/map-limited/map-limited.ts:10
↓ 1 callers
Function
markFieldsOf
({ kind, feature, reason, props, }: Mark)
mods/telemetry/hooks/entries/mark-fields-of/mark-fields-of.ts:17
↓ 1 callers
Function
markStale
(owner: string, repo: string)
scripts/sweep.ts:45
↓ 1 callers
Function
markTabSwitch
(engine: Host, tab: (typeof Record.TABS)[number])
mods/diff/hooks/register.ts:411
↓ 1 callers
Function
mergeBaseCandidatesOf
( run: Types.GitRun, defaultBranch: string, )
mods/diff/hooks/git/probes/merge-base-candidates-of/merge-base-candidates-of.ts:17
↓ 1 callers
Function
mergedWithUntracked
( result: Types.NumstatResult, untracked: readonly Types.FileStat[] | null, )
mods/diff/hooks/git/tiers/with-untracked/merged-with-untracked/merged-with-untracked.ts:15
↓ 1 callers
Function
messageOf
()
mods/diff/hooks/views/body/plan/segments/segments-of.ts:106
↓ 1 callers
Function
middleOf
(path: string)
mods/diff/hooks/git/rename-display-of/rename-display-of.ts:45
↓ 1 callers
Function
missingBaseOf
( run: Types.GitRun, defaultBranch: string, )
mods/diff/hooks/git/probes/missing-base-of/missing-base-of.ts:15
↓ 1 callers
Function
moreOf
(way: 'up' | 'down', count: number)
mods/diff/hooks/views/dialog-pane/dialog-pane.tsx:98
↓ 1 callers
Function
mtimeOf
(engine: Host)
mods/diff/hooks/mtime-of/mtime-of.ts:11
↓ 1 callers
Function
nameOf
()
mods/diff/hooks/pane-state/mode-label-of/mode-label-of.ts:28
↓ 1 callers
Function
noopActionsOf
()
mods/diff/tests/fixtures/pane-view/noop-actions-of.ts:9
↓ 1 callers
Function
noteOf
(entry: Entries.BodyEntry)
mods/diff/hooks/views/dialog-pane/dialog-pane.tsx:80
↓ 1 callers
Function
ok
(stdout = '')
mods/diff/tests/fixtures/scripted/ok.ts:10
↓ 1 callers
Function
onFeature
()
mods/diff/tests/git/probes/branch-base-of.test.ts:14
↓ 1 callers
Function
onFeatureNoUntrackedOf
()
mods/diff/tests/git/fetch-diff.test.ts:61
↓ 1 callers
Function
openOnFirstEdit
(engine: Host)
mods/diff/hooks/register.ts:418
↓ 1 callers
Function
openedOf
()
mods/diff/hooks/views/body/plan/segments/segments-of.ts:123
↓ 1 callers
Function
orgServerNames
(policy: Settings)
mods/sec-default/hooks/policy/managed-tools-restored/is-org-tool/org-server-names/org-server-names.ts:13
↓ 1 callers
Function
pagedEdgeOf
(way: 'up' | 'down', count: number)
mods/diff/hooks/views/dialog-pane/dialog-pane.tsx:105
↓ 1 callers
Function
pastUsers
( e: E, next: Provided.ProvidedNext<E, R>, )
mods/sec-default/hooks/past-users/past-users.ts:16
↓ 1 callers
Function
pickedTurnOf
(model: PaneModel)
mods/diff/hooks/pane-state/picked-turn-of/picked-turn-of.ts:11
↓ 1 callers
Function
placeholderOf
(detail: DetailModel)
mods/diff/hooks/views/detail/placeholder-of/placeholder-of.ts:15
↓ 1 callers
Function
post
( fields: Entries.Fields, method: Entries.Method, )
mods/telemetry/hooks/telemetry-of/telemetry-of.ts:20
↓ 1 callers
Function
present
( children: readonly (RenderElement | null)[], )
mods/diff/hooks/views/sections/present/present.ts:12
↓ 1 callers
Function
probeBackend
(engine: Host)
mods/diff/hooks/register.ts:109
↓ 1 callers
Function
probeOf
(budget: number)
mods/diff/tests/git/probes/datings-of.test.ts:33
↓ 1 callers
Function
queued
( fields: Entries.Fields, method: Entries.Method, )
mods/telemetry/hooks/telemetry-of/telemetry-of.ts:60
↓ 1 callers
Function
read
()
mods/sec-default/tests/policy/create-policy-memo.test.ts:13
↓ 1 callers
Function
readHeadKey
()
mods/diff/hooks/register.ts:256
↓ 1 callers
Function
record_pending_warnings
Mark file:rule pairs as pending for the Stop-hook outcome sweep.
plugins/security-guidance/hooks/security_reminder_hook.py:321
↓ 1 callers
Function
record_touched_path
Append a file path to the touched_paths list (deduped, capped at 200). Stop is the consumer and clears under the same lock it reads with; UPS
plugins/security-guidance/hooks/diffstate.py:57
↓ 1 callers
Function
recorded
( listings: Readonly<Record<string, ReadonlyMap<string, Git.EntryKind>>>, head: string, )
mods/diff/tests/git/probes/head-key-of.test.ts:16
↓ 1 callers
Function
recordingBackendHostOf
( script: Readonly<Record<string, ProcessRunResult>>, )
mods/diff/tests/fixtures/backend-of/recording-backend-host-of.ts:14
↓ 1 callers
Function
refusalFor
(entry: unknown)
mods/telemetry/tests/register.test.ts:178
↓ 1 callers
Function
registeredToolOf
(plugin: string, name: string)
mods/sec-default/tests/fixtures/registered-tool-of.ts:8
↓ 1 callers
Function
renameDisplayOf
(oldPath: string, newPath: string)
mods/diff/hooks/git/rename-display-of/rename-display-of.ts:13
← previous
next →
201–300 of 532, ranked by callers