Skip to content

Commit 0015fb8

Browse files
committed
feat: inject DirectoriesInterface into MCP server command and remove unused dependencies in TreeSourceBootloader
1 parent 2fe1680 commit 0015fb8

File tree

2 files changed

+1
-4
lines changed

2 files changed

+1
-4
lines changed

src/Console/MCPServerCommand.php

+1
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,7 @@ public function __invoke(Container $container, DirectoriesInterface $dirs, Appli
109109
bindings: new Scope(
110110
name: AppScope::Mcp,
111111
bindings: [
112+
DirectoriesInterface::class => $dirs,
112113
ProjectServiceInterface::class => $projectServiceFactory->create(),
113114
HasPrefixLoggerInterface::class => $logger,
114115
ConfigLoaderInterface::class => $loader,

src/Source/Tree/TreeSourceBootloader.php

-4
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,7 @@
55
namespace Butschster\ContextGenerator\Source\Tree;
66

77
use Butschster\ContextGenerator\Application\Bootloader\SourceFetcherBootloader;
8-
use Butschster\ContextGenerator\Application\Logger\HasPrefixLoggerInterface;
98
use Butschster\ContextGenerator\DirectoriesInterface;
10-
use Butschster\ContextGenerator\Lib\Content\ContentBuilderFactory;
119
use Butschster\ContextGenerator\Source\Registry\SourceRegistryInterface;
1210
use Spiral\Boot\Bootloader\Bootloader;
1311
use Spiral\Core\FactoryInterface;
@@ -21,8 +19,6 @@ public function defineSingletons(): array
2119
TreeSourceFetcher::class => static fn(
2220
FactoryInterface $factory,
2321
DirectoriesInterface $dirs,
24-
ContentBuilderFactory $builderFactory,
25-
HasPrefixLoggerInterface $logger,
2622
): TreeSourceFetcher => $factory->make(TreeSourceFetcher::class, [
2723
'basePath' => (string) $dirs->getRootPath(),
2824
]),

0 commit comments

Comments
 (0)