-
Notifications
You must be signed in to change notification settings - Fork 684
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix path to server when running platform neutral vsix #5940
Conversation
@@ -673,7 +673,13 @@ function getServerFileName(platformInfo: PlatformInformation) { | |||
extension = '.dll'; | |||
} | |||
|
|||
return `${serverFileName}${extension}`; | |||
let pathWithExtension = `${serverFilePath}${extension}`; | |||
if (!fs.existsSync(pathWithExtension)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So on Linux we don't set extension, expect this to fail and then take the if block?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
On linux, if the platform specific version is installed there will be a 'Microsoft.CodeAnalysis.LanguageServer' file (no extension). That will exist, so we won't take this block.
If we're using the neutral version, there will be no 'Microsoft.CodeAnalysis.LanguageServer' file, we'll hit this and find the dll instead.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh right, I forgot there'd be no extension. It might make sense to put a comment there that the lack of setting that is intentional, but...
@@ -673,7 +673,13 @@ function getServerFileName(platformInfo: PlatformInformation) { | |||
extension = '.dll'; | |||
} | |||
|
|||
return `${serverFileName}${extension}`; | |||
let pathWithExtension = `${serverFilePath}${extension}`; | |||
if (!fs.existsSync(pathWithExtension)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh right, I forgot there'd be no extension. It might make sense to put a comment there that the lack of setting that is intentional, but...
Won't fully work until dotnet/roslyn#69110 is in