ReSharper command-line tools cross platform w\Xamarin
I have a Xamarin.Forms project that targets iOS. I'm wanting to run the ReSharper analysis on the mac build agent. I see that Jetbrains has released a cross-plat toolset.
Following the instructions here, I installed the toolset on my mac.
When I try to run inspect code, it doesn't work. It looks like it is pulling the toolset from the wrong location.

So, I tried forcing mono and the toolset path:

As you can see, this doesn't work either.
Any help would be appreciated.
TIA
Please sign in to leave a comment.
Hi Andy!
Mono parameter should point to executable, not directory.
Also, toolset path is not necessary when mono is specified.
Take a closer look at command line tool's parameters
https://www.jetbrains.com/help/resharper/InspectCode.html#inspection-parameters
Thanks Slava.
You're right, I missed the mono exe. So I tried it again, but was unsuccessful.
If you're telling me I don't need to set the toolset path, I'm not sure what other options I need to be setting here to make this work.
Thanks
Okay then, auto-detection didn't work.
Better to file an issue in youtrack.
And, what if you'd specify mono and toolset both? Does it help?
So, is filing the issue in youtrack something I need to do?
Yes please.
Repro project will be very useful.
Also, OS type and version, Mono version and other details.
Before filing the issue - why so strange path to msbuild executable?
It should be in the same folder as mono executable itself.
How do you build you project under Mono?
There should be path to correct msbuild.
I pulled that path from my build pipeline for when it actually builds the solution. It does reside there:


However, it looks like it does actually live in the mono bin directory as well. I went ahead and tried it pointing it to the mono directory.
Are you sure it resides there? Error message says it's not.
You should be able to execute %path_to_mono% %path_to_msbuild%.
What that command's output says?
But there is no Commands part in msbuild path while in your example with inspectcode there is...
But, msbuild and mono does reside in both places. I haven't mucked with any of this, this is how it was setup after installing VS for mac.

But, as you pointed out, looks like I left commands in one of the earlier attempts. Oops. Here it is without.

toolset-path should point to actual msbuild dll which mono can execute, not to a shell script. Something like:
/Library/Frameworks/Mono.framework/Versions/6.10.0/lib/mono/msbuild/Current/bin/MSBuild.dll
Ok, that's helpful.
It seems
--toolset-path=/Library/Frameworks/Mono.framework/Versions/Current/lib/mono/msbuild/Current/bin/MSBuild.dll
does the trick. Thanks!