Honor selected JDK during Maven detection
This commit is contained in:
@@ -15,7 +15,7 @@ from datetime import datetime
|
||||
from pathlib import Path
|
||||
from typing import Callable, Iterable, Mapping
|
||||
|
||||
from .environment import discover_executable
|
||||
from .environment import discover_executable, resolve_tool_path
|
||||
from .scanner import ScanResult
|
||||
|
||||
|
||||
@@ -249,8 +249,8 @@ def build_deployment_plan(scan: ScanResult, config: DeploymentConfig) -> list[De
|
||||
def _tool_command(config: DeploymentConfig, tool_name: str, fallback: str) -> str:
|
||||
configured = config.tool_paths.get(tool_name) if config.tool_paths else None
|
||||
if configured:
|
||||
path = Path(configured)
|
||||
if path.exists():
|
||||
path = resolve_tool_path(tool_name, configured)
|
||||
if path:
|
||||
return str(path)
|
||||
|
||||
discovered = discover_executable(tool_name, config.tool_search_roots)
|
||||
|
||||
Reference in New Issue
Block a user