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

Function pathWithin

script/ghmock/gitfixture.go:114–117  ·  view source on GitHub ↗
(root, path string)

Source from the content-addressed store, hash-verified

112}
113
114func pathWithin(root, path string) bool {
115 rel, err := filepath.Rel(root, path)
116 return err == nil && filepath.IsLocal(rel)
117}
118
119// copyGitTree preserves the index, untracked files and worktree metadata, which
120// a clone would lose. It copies file contents, never hardlinks. Only Git's path

Callers 8

writeTarGzipFunction · 0.85
portableGitPathFunction · 0.85
copyConfigTreeFunction · 0.85
extractTestArchiveFunction · 0.85
gitWorkDirFunction · 0.85
copyGitTreeFunction · 0.85
copyGitPathFileFunction · 0.85
relocateGitAlternatesFunction · 0.85

Calls 1

IsLocalMethod · 0.65

Tested by 1

extractTestArchiveFunction · 0.68