Download mods/diff/hooks/git/tiers/fetch-context-of/fetch-context-of.ts from SaylorTwift/claude-code: direct link, hf CLI and curl.
- Browser
- Download file 639 Bytes
-
https://huggingface.co/SaylorTwift/claude-code/resolve/main/mods/diff/hooks/git/tiers/fetch-context-of/fetch-context-of.ts
- Command line
-
hf download hf://SaylorTwift/claude-code/mods/diff/hooks/git/tiers/fetch-context-of/fetch-context-of.ts
-
curl -L -o fetch-context-of.ts https://huggingface.co/SaylorTwift/claude-code/resolve/main/mods/diff/hooks/git/tiers/fetch-context-of/fetch-context-of.ts
639 Bytes
| import Limits from '../../../limits' | |
| import Probes from '../../probes' | |
| import type Types from '../../types' | |
| /** | |
| * The context every tier of a fetch shares: the host's pinned git, the | |
| * repository, the mode, and one stamp probe over the working tree's top. | |
| * | |
| * @param deps the host | |
| * @param mode the comparison asked for | |
| * @returns the context | |
| */ | |
| export const fetchContextOf = ( | |
| deps: Types.GitDeps, | |
| mode: Types.BaseMode, | |
| ): Types.FetchContext => ({ | |
| deps, | |
| run: deps.run, | |
| repository: deps.repository, | |
| mode, | |
| stamps: Probes.stampProbeOf( | |
| deps, | |
| deps.repository.toplevel, | |
| Limits.MAX_LISTED_DIRECTORIES, | |
| ), | |
| }) | |