maven-local-repo-mcp
v1.0.5
Published
[](https://cursor.com/install-mcp?name=maven-local-repo-mcp&config=JTdCJTIyY29tbWFuZCUyMiUzQSUyMm5weCUyMC15JTIwbWF2ZW4tbG9jYWwtcmVwby1tY3AlMjIlMkMlMjJlbnYlMjIlM0ElN0IlMjJNQVZFTl9NQ1BfT
Readme
Maven Local Repository MCP
Get Started
Why you need this MCP
When coding in java with Cursor or other AI-IDEs, your Maven dependencies are not visible for the AI because they are stored in the local Maven repository as .jar files. This significantly limits the AI's ability to understand your code and provide accurate suggestions especially for enterprise internal packages. This MCP provides a tool to extract the source code from your local Maven repository and make it available to the AI.
Prerequisites
- Local JDK >= jdk17 installed and configured in your PATH (JAVA_HOME).
- Local Maven installed and configured in your PATH (M2_HOME).
How it works
- The MCP server scans your local Maven repository for .jar files.
- Calls to your local
jarbinary to analysis the fqn(full qualified name) and packages relationship. - Calls to your local
jarbinary to unpack the jar file when the AI needs the source code. - Calls to the packaged fernflower library from JetBrain to decompile the .class file back to .java file.
Configuration
Enviorment Vars
MAVEN_MCP_LOOKUPS: A comma-separated list of organizations to scan for .jar files. Defaults to com which means to search for packages under organization com.*, example: com.trip, wider range will cause the mcp to take longer to start. It is recommended to set this to your own organization, e.g. com.mycompany.
