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

Function fileURL

git/client_test.go:1612–1618  ·  view source on GitHub ↗
(filePath string)

Source from the content-addressed store, hash-verified

1610}
1611
1612func fileURL(filePath string) string {
1613 urlPath := filepath.ToSlash(filePath)
1614 if filepath.VolumeName(filePath) != "" {
1615 urlPath = "/" + urlPath
1616 }
1617 return (&url.URL{Scheme: "file", Path: urlPath}).String()
1618}
1619
1620func runGitAt(t *testing.T, dir string, args ...string) string {
1621 t.Helper()

Callers 2

fileURLMethod · 0.85

Calls 1

StringMethod · 0.65

Tested by

no test coverage detected