MCPcopy Index your code
hub / github.com/anomalyco/opencode / normalizeRepositoryInput

Function normalizeRepositoryInput

packages/opencode/src/util/repository.ts:64–70  ·  view source on GitHub ↗
(input: string)

Source from the content-addressed store, hash-verified

62}
63
64function normalizeRepositoryInput(input: string) {
65 return input
66 .trim()
67 .replace(/^git\+/, "")
68 .replace(/#.*$/, "")
69 .replace(/\/+$/, "")
70}
71
72function trimGitSuffix(input: string) {
73 return input.replace(/\.git$/, "")

Callers 2

parseRepositoryReferenceFunction · 0.85
parseGitHubRemoteFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected