MCPcopy Create free account
hub / github.com/Noumena-Network/code / parseRegistrationCalls

Function parseRegistrationCalls

scripts/generate_slash_command_appendix.mjs:566–576  ·  view source on GitHub ↗
(source, localImportMap, gate = 'always')

Source from the content-addressed store, hash-verified

564}
565
566function parseRegistrationCalls(source, localImportMap, gate = 'always') {
567 const rows = []
568 for (const match of source.matchAll(/\b(register[A-Za-z_$][\w$]*)\(\)/g)) {
569 const symbol = match[1]
570 if (symbol === 'registerBundledSkill' || symbol === 'registerBuiltinPlugin') continue
571 const specifier = localImportMap.get(symbol)
572 if (!specifier) continue
573 rows.push({ symbol, specifier, gate })
574 }
575 return rows
576}
577
578function resolveGate(entry, importInfo) {
579 const rawGate = entry.gate || importInfo?.gate || 'always'

Callers 1

collectBundledSkillRowsFunction · 0.85

Calls 1

getMethod · 0.45

Tested by

no test coverage detected