MCPcopy Create free account
hub / github.com/dmno-dev/bumpy / catalogNameFromRange

Function catalogNameFromRange

packages/bumpy/src/utils/package-manager.ts:189–191  ·  view source on GitHub ↗

Extract the catalog name from a `catalog:` / `catalog: ` range, normalizing the default alias

(range: string)

Source from the content-addressed store, hash-verified

187
188/** Extract the catalog name from a `catalog:` / `catalog:<name>` range, normalizing the default alias */
189function catalogNameFromRange(range: string): string {
190 return normalizeCatalogName(range.slice('catalog:'.length).trim());
191}
192
193/** Resolve a specific dependency's catalog: reference */
194export function resolveCatalogDep(depName: string, range: string, catalogs: CatalogMap): string | null {

Callers 2

resolveCatalogDepFunction · 0.85
isCatalogRefAffectedFunction · 0.85

Calls 1

normalizeCatalogNameFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…