diff --git a/src/fetchMetals.ts b/src/fetchMetals.ts index 193ec870..088b1c26 100644 --- a/src/fetchMetals.ts +++ b/src/fetchMetals.ts @@ -16,9 +16,12 @@ export function fetchMetals({ (p) => !p.startsWith("-agentlib") ); + const binaryVersion = serverVersion > "0.11.2" ? "2.13" : "2.12" + console.log(serverVersion) + console.log(binaryVersion) const serverDependency = serverVersion.includes(":") ? serverVersion - : `org.scalameta:metals_2.12:${serverVersion}`; + : `org.scalameta:metals_${binaryVersion}:${serverVersion}`; return spawn( javaPath,