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

Function isCustomCommandAllowed

packages/bumpy/src/core/config.ts:161–168  ·  view source on GitHub ↗

Check if a package is allowed to define custom commands via package.json

(pkgName: string, config: BumpyConfig)

Source from the content-addressed store, hash-verified

159
160/** Check if a package is allowed to define custom commands via package.json */
161function isCustomCommandAllowed(pkgName: string, config: BumpyConfig): boolean {
162 const { allowCustomCommands } = config;
163 if (allowCustomCommands === true) return true;
164 if (Array.isArray(allowCustomCommands)) {
165 return allowCustomCommands.some((pattern) => matchGlob(pkgName, pattern));
166 }
167 return false;
168}
169
170export function getBumpyDir(rootDir: string): string {
171 return resolve(rootDir, BUMPY_DIR);

Callers 1

loadPackageConfigFunction · 0.85

Calls 1

matchGlobFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…