MCPcopy Create free account
hub / github.com/dyoshikawa/rulesync / getFactory

Method getFactory

src/features/rules/rules-processor.ts:1565–1572  ·  view source on GitHub ↗

* Get the factory for a specific tool target. * This is a static version of the internal getFactory for external use. * @param target - The tool target. Must be a valid RulesProcessorToolTarget. * @returns The factory for the target, or undefined if not found.

(target: ToolTarget)

Source from the content-addressed store, hash-verified

1563 * @returns The factory for the target, or undefined if not found.
1564 */
1565 static getFactory(target: ToolTarget): ToolRuleFactory | undefined {
1566 // Validate that target is supported
1567 const result = RulesProcessorToolTargetSchema.safeParse(target);
1568 if (!result.success) {
1569 return undefined;
1570 }
1571 return toolRuleFactories.get(result.data);
1572 }
1573
1574 private generateToonReferencesSection(toolRules: ToolRule[]): string {
1575 const toolRulesWithoutRoot = toolRules.filter((rule) => !rule.isRoot());

Callers 10

loadRulesyncFilesMethod · 0.95
loadToolFilesMethod · 0.95
computeRootFileOwnershipFunction · 0.45
getToolPathMappingFunction · 0.45
loadToolFilesMethod · 0.45
loadToolIgnoresMethod · 0.45
loadToolFilesMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected