MCPcopy Create free account
hub / github.com/MatterAIOrg/OrbCode / resolveLinkTarget

Function resolveLinkTarget

src/config/links.ts:99–104  ·  view source on GitHub ↗
(input: string)

Source from the content-addressed store, hash-verified

97 * cwd — into an absolute filesystem path. Returns undefined for empty input.
98 */
99export function resolveLinkTarget(input: string): string | undefined {
100 let value = input.trim()
101 if (!value) return undefined
102 if (value.startsWith("~/")) value = path.join(os.homedir(), value.slice(2))
103 return path.resolve(value)
104}
105
106export interface LinkResult {
107 ok: boolean

Callers 2

loadLinksFunction · 0.85
addLinkFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected