Skip to main content
Glama

CTX: Context as Code (CaC) tool

by context-hub
MIT License
235
  • Apple
  • Linux
PatternExclusion.php917 B
<?php declare(strict_types=1); namespace Butschster\ContextGenerator\Config\Exclude; use Butschster\ContextGenerator\Config\Import\PathMatcher; /** * Glob pattern exclusion pattern * * Excludes files and directories using glob patterns * with wildcards like *, **, ?, and other glob syntax */ final readonly class PatternExclusion extends AbstractExclusion { private PathMatcher $matcher; public function __construct(string $pattern) { parent::__construct($pattern); $this->matcher = new PathMatcher($pattern); } /** * Check if a path matches this exclusion pattern * * Uses glob pattern matching via PathMatcher */ public function matches(string $path): bool { return $this->matcher->isMatch($path); } public function jsonSerialize(): array { return [ 'pattern' => $this->pattern, ]; } }

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/context-hub/generator'

If you have feedback or need assistance with the MCP directory API, please join our Discord server