Skip to content

Commit 6013d92

Browse files
Merge pull request #1691 from DustinCampbell/update-omnisharp
Update to latest OmniSharp build and update required Mono version
2 parents 26508b3 + 001e35a commit 6013d92

File tree

4 files changed

+47
-71
lines changed

4 files changed

+47
-71
lines changed

CHANGELOG.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,11 @@
2020

2121
#### Project System
2222

23-
* Mono targets and tasks are now located properly when Mono is installed. This enables support for many Mono-based projects types, such as Xamarin.iOS, Xamarin.Android, MonoGame, etc. ([#1597](https://github.com/OmniSharp/omnisharp-vscode/issues/1597), [#1624](https://github.com/OmniSharp/omnisharp-vscode/issues/1624), [#1396](https://github.com/OmniSharp/omnisharp-vscode/issues/1396) [omnisharp-roslyn#892](https://github.com/OmniSharp/omnisharp-roslyn/issues/892), PR: [omnisharp-roslyn#923](https://github.com/OmniSharp/omnisharp-roslyn/pull/923))
24-
* Use MSBuild solution parsing API, which is the official parser for handling weird solution file cases. ([1580](https://github.com/OmniSharp/omnisharp-vscode/issues/1580), PR: [omnisharp-roslyn#897](https://github.com/OmniSharp/omnisharp-roslyn/pull/897))
23+
* Mono targets and tasks are now better located when Mono is installed. This enables support for many Mono-based projects types, such as Xamarin.iOS, Xamarin.Android, MonoGame, etc. ([#1597](https://github.com/OmniSharp/omnisharp-vscode/issues/1597), [#1624](https://github.com/OmniSharp/omnisharp-vscode/issues/1624), [#1396](https://github.com/OmniSharp/omnisharp-vscode/issues/1396) [omnisharp-roslyn#892](https://github.com/OmniSharp/omnisharp-roslyn/issues/892), PR: [omnisharp-roslyn#923](https://github.com/OmniSharp/omnisharp-roslyn/pull/923))
24+
* Use new solution parer to be more resilient against invalid solution files. ([1580](https://github.com/OmniSharp/omnisharp-vscode/issues/1580), [1645](https://github.com/OmniSharp/omnisharp-vscode/issues/1645), PRs: [omnisharp-roslyn#897](https://github.com/OmniSharp/omnisharp-roslyn/pull/897) and [omnisharp-roslyn#918](https://github.com/OmniSharp/omnisharp-roslyn/pull/918))
2525
* The MSBuild project system now calls the "Compile" target rather than the "ResolveReferences" target when processing MSBuild files. This has the effect of ensuring that other targets have the opportunity to run (such as targets that generate files) while still not building any output binaries. ([#1531](https://github.com/OmniSharp/omnisharp-vscode/issues/1531))
2626
* Binding redirects added for MSBuild assemblies, fixing issues with MSBuild tasks built with different versions of MSBuild. ([omnisharp-roslyn#903](https://github.com/OmniSharp/omnisharp-roslyn/issues/903))
27-
* The OmniSharp serverhas updated to the latest MSBuild. ([omnisharp-roslyn#904](https://github.com/OmniSharp/omnisharp-roslyn/pull/904), PR: [omnisharp-roslyn#907](https://github.com/OmniSharp/omnisharp-roslyn/pull/907))
27+
* The OmniSharp server has updated to the latest MSBuild. ([omnisharp-roslyn#904](https://github.com/OmniSharp/omnisharp-roslyn/pull/904), PR: [omnisharp-roslyn#907](https://github.com/OmniSharp/omnisharp-roslyn/pull/907))
2828

2929
#### Scripting
3030

@@ -39,7 +39,7 @@
3939
* Added `type` property to `csharp.unitTestDebuggingOptions` to allow debugging tests with 'clr' debugger (Windows only). ([#1586](https://github.com/OmniSharp/omnisharp-vscode/issues/1586), PR: [#1663](https://github.com/OmniSharp/omnisharp-vscode/pull/1663))
4040
* The `[csharp]` configuration section is now checked for formatting options. ([#1574](https://github.com/OmniSharp/omnisharp-vscode/issues/1574)) _(Contributed by [@filipw](https://github.com/filipw))_
4141
* All project systems (project.json, MSBuild, CSX Scripting) now support an "Enabled" property that can be configured in omnisharp.json. (PR: [omnisharp-roslyn#902](https://github.com/OmniSharp/omnisharp-roslyn/pull/902)) _(Contributed by [@filipw](https://github.com/filipw))_
42-
* The OmniSharp server has been updated to Roslyn 2.3.0-beta2, which adds support for C# 7.1 (PRs: [omnisharp-roslyn#900](https://github.com/OmniSharp/omnisharp-roslyn/pull/900) and [omnisharp-roslyn#901](https://github.com/OmniSharp/omnisharp-roslyn/pull/901))
42+
* The OmniSharp server has been updated to Roslyn 2.3.0, which adds support for C# 7.1 (PRs: [omnisharp-roslyn#900](https://github.com/OmniSharp/omnisharp-roslyn/pull/900), [omnisharp-roslyn#901](https://github.com/OmniSharp/omnisharp-roslyn/pull/901), [omnisharp-roslyn#930](https://github.com/OmniSharp/omnisharp-roslyn/pull/930) and [omnisharp-roslyn#931](https://github.com/OmniSharp/omnisharp-roslyn/pull/931))
4343

4444
## 1.11.0 (June 27, 2017)
4545

package.json

Lines changed: 38 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "csharp",
33
"publisher": "ms-vscode",
4-
"version": "1.12.0-beta4",
4+
"version": "1.12.0-beta5",
55
"description": "C# for Visual Studio Code (powered by OmniSharp).",
66
"displayName": "C#",
77
"author": "Microsoft Corporation",
@@ -67,100 +67,79 @@
6767
},
6868
"runtimeDependencies": [
6969
{
70-
"description": "Mono Runtime (Linux / x86)",
71-
"url": "https://download.visualstudio.microsoft.com/download/pr/11004046/b55a892377b7f8157e3ab28a2f8a3a1f/mono.linux-x86-5.2.0.209.zip",
72-
"fallbackUrl": "https://omnisharpdownload.blob.core.windows.net/ext/mono.linux-x86-5.2.0.209.zip",
73-
"installPath": "./bin",
70+
"description": "OmniSharp for Windows (.NET 4.6 / x86)",
71+
"url": "https://download.visualstudio.microsoft.com/download/pr/11071105/cbf554a87cbe90e7f290ce79398776bf/omnisharp-win-x86-1.23.1.zip",
72+
"fallbackUrl": "https://omnisharpdownload.blob.core.windows.net/ext/omnisharp-win-x86-1.23.1.zip",
73+
"installPath": ".omnisharp",
7474
"platforms": [
75-
"linux"
75+
"win32"
7676
],
7777
"architectures": [
7878
"x86"
7979
],
80-
"binaries": [
81-
"./mono.linux-x86",
82-
"./run"
83-
],
84-
"installTestPath": "./bin/mono.linux-x86"
80+
"installTestPath": "./.omnisharp/OmniSharp.exe"
8581
},
8682
{
87-
"description": "Mono Runtime (Linux / x64)",
88-
"url": "https://download.visualstudio.microsoft.com/download/pr/11004046/b55a892377b7f8157e3ab28a2f8a3a1f/mono.linux-x86_64-5.2.0.209.zip",
89-
"fallbackUrl": "https://omnisharpdownload.blob.core.windows.net/ext/mono.linux-x86_64-5.2.0.209.zip",
90-
"installPath": "./bin",
83+
"description": "OmniSharp for Windows (.NET 4.6 / x64)",
84+
"url": "https://download.visualstudio.microsoft.com/download/pr/11071104/51b457cd47f5348658ce356d3e90c75c/omnisharp-win-x64-1.23.1.zip",
85+
"fallbackUrl": "https://omnisharpdownload.blob.core.windows.net/ext/omnisharp-win-x64-1.23.1.zip",
86+
"installPath": ".omnisharp",
9187
"platforms": [
92-
"linux"
88+
"win32"
9389
],
9490
"architectures": [
9591
"x86_64"
9692
],
97-
"binaries": [
98-
"./mono.linux-x86_64",
99-
"./run"
100-
],
101-
"installTestPath": "./bin/mono.linux-x86_64"
93+
"installTestPath": "./.omnisharp/OmniSharp.exe"
10294
},
10395
{
104-
"description": "Mono Runtime (macOS)",
105-
"url": "https://download.visualstudio.microsoft.com/download/pr/11004046/b55a892377b7f8157e3ab28a2f8a3a1f/mono.osx-5.2.0.209.zip",
106-
"fallbackUrl": "https://omnisharpdownload.blob.core.windows.net/ext/mono.osx-5.2.0.209.zip",
107-
"installPath": "./bin",
96+
"description": "OmniSharp for OSX",
97+
"url": "https://download.visualstudio.microsoft.com/download/pr/11071103/4df6a2993b53c7ff89ce8e7f93ef5d15/omnisharp-osx-1.23.1.zip",
98+
"fallbackUrl": "https://omnisharpdownload.blob.core.windows.net/ext/omnisharp-osx-1.23.1.zip",
99+
"installPath": ".omnisharp",
108100
"platforms": [
109101
"darwin"
110102
],
111103
"binaries": [
112104
"./mono.osx",
113105
"./run"
114106
],
115-
"installTestPath": "./bin/mono.osx"
107+
"installTestPath": "./.omnisharp/mono.osx"
116108
},
117109
{
118-
"description": "Mono Framework Assemblies",
119-
"url": "https://download.visualstudio.microsoft.com/download/pr/11004046/b55a892377b7f8157e3ab28a2f8a3a1f/framework-5.2.0.209.zip",
120-
"fallbackUrl": "https://omnisharpdownload.blob.core.windows.net/ext/framework-5.2.0.209.zip",
121-
"installPath": "./bin/framework",
110+
"description": "OmniSharp for Linux (x86)",
111+
"url": "https://download.visualstudio.microsoft.com/download/pr/11071102/76070e75070ac32ed0f8cac1e753b21e/omnisharp-linux-x86-1.23.1.zip",
112+
"fallbackUrl": "https://omnisharpdownload.blob.core.windows.net/ext/omnisharp-linux-x86-1.23.1.zip",
113+
"installPath": ".omnisharp",
122114
"platforms": [
123-
"darwin",
124115
"linux"
125116
],
126-
"installTestPath": "./bin/framework/mscorlib.dll"
127-
},
128-
{
129-
"description": "OmniSharp (.NET 4.6 / x86)",
130-
"url": "https://download.visualstudio.microsoft.com/download/pr/11004046/b55a892377b7f8157e3ab28a2f8a3a1f/omnisharp-win-x86-1.23.0-alpha1.zip",
131-
"fallbackUrl": "https://omnisharpdownload.blob.core.windows.net/ext/omnisharp-win-x86-1.23.0-alpha1.zip",
132-
"installPath": "./bin/omnisharp",
133-
"platforms": [
134-
"win32"
135-
],
136117
"architectures": [
137-
"x86"
118+
"x86",
119+
"i686"
120+
],
121+
"binaries": [
122+
"./mono.linux-x86",
123+
"./run"
138124
],
139-
"installTestPath": "./bin/omnisharp/OmniSharp.exe"
125+
"installTestPath": "./.omnisharp/mono.linux-x86"
140126
},
141127
{
142-
"description": "OmniSharp (.NET 4.6 / x64)",
143-
"url": "https://download.visualstudio.microsoft.com/download/pr/11004046/b55a892377b7f8157e3ab28a2f8a3a1f/omnisharp-win-x64-1.23.0-alpha1.zip",
144-
"fallbackUrl": "https://omnisharpdownload.blob.core.windows.net/ext/omnisharp-win-x64-1.23.0-alpha1.zip",
145-
"installPath": "./bin/omnisharp",
128+
"description": "OmniSharp for Linux (x64)",
129+
"url": "https://download.visualstudio.microsoft.com/download/pr/11071101/d1308f9fa4e3dcf36eea1a1f731decd7/omnisharp-linux-x64-1.23.1.zip",
130+
"fallbackUrl": "https://omnisharpdownload.blob.core.windows.net/ext/omnisharp-linux-x64-1.23.1.zip",
131+
"installPath": ".omnisharp",
146132
"platforms": [
147-
"win32"
133+
"linux"
148134
],
149135
"architectures": [
150136
"x86_64"
151137
],
152-
"installTestPath": "./bin/omnisharp/OmniSharp.exe"
153-
},
154-
{
155-
"description": "OmniSharp (Mono 4.6)",
156-
"url": "https://download.visualstudio.microsoft.com/download/pr/11004046/b55a892377b7f8157e3ab28a2f8a3a1f/omnisharp-mono-1.23.0-alpha1.zip",
157-
"fallbackUrl": "https://omnisharpdownload.blob.core.windows.net/ext/omnisharp-mono-1.23.0-alpha1.zip",
158-
"installPath": "./bin/omnisharp",
159-
"platforms": [
160-
"darwin",
161-
"linux"
138+
"binaries": [
139+
"./mono.linux-x86_64",
140+
"./run"
162141
],
163-
"installTestPath": "./bin/omnisharp/OmniSharp.exe"
142+
"installTestPath": "./.omnisharp/mono.linux-x86_64"
164143
},
165144
{
166145
"description": ".NET Core Debugger (Windows / x64)",

src/common.ts

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,6 @@ export function getExtensionPath() {
2222
return extensionPath;
2323
}
2424

25-
export function getBinPath() {
26-
return path.resolve(getExtensionPath(), "bin");
27-
}
28-
2925
export function isBoolean(obj: any): obj is boolean {
3026
return obj === true || obj === false;
3127
}

src/omnisharp/launcher.ts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -219,10 +219,10 @@ function getConfigurationValue(globalConfig: vscode.WorkspaceConfiguration, csha
219219
}
220220

221221
function getLaunchPath(platformInfo: PlatformInformation): string {
222-
const binPath = util.getBinPath();
222+
const binPath = path.resolve(util.getExtensionPath(), '.omnisharp');
223223

224224
return platformInfo.isWindows()
225-
? path.join(binPath, 'omnisharp', 'OmniSharp.exe')
225+
? path.join(binPath, 'OmniSharp.exe')
226226
: path.join(binPath, 'run');
227227
}
228228

@@ -272,6 +272,7 @@ function launchNixMono(launchPath: string, cwd: string, args: string[]): Promise
272272
return canLaunchMono()
273273
.then(() => {
274274
let argsCopy = args.slice(0); // create copy of details args
275+
argsCopy.unshift("--assembly-loader=strict");
275276
argsCopy.unshift(launchPath);
276277

277278
let process = spawn('mono', argsCopy, {
@@ -289,12 +290,12 @@ function launchNixMono(launchPath: string, cwd: string, args: string[]): Promise
289290

290291
function canLaunchMono(): Promise<void> {
291292
return new Promise<void>((resolve, reject) => {
292-
hasMono('>=4.6.0').then(success => {
293+
hasMono('>=5.2.0').then(success => {
293294
if (success) {
294295
resolve();
295296
}
296297
else {
297-
reject(new Error('Cannot start Omnisharp because Mono version >=4.0.1 is required.'));
298+
reject(new Error('Cannot start Omnisharp because Mono version >=5.2.0 is required.'));
298299
}
299300
});
300301
});

0 commit comments

Comments
 (0)