CSharpAnalyzers / ExceptionalReSharper

Extension for ReSharper which analyzes thrown and documented C# exceptions and suggests improvements
Microsoft Public License
125 stars 30 forks source link

Full Guide for manual installation? #102

Closed hhu-mahmoud closed 4 years ago

hhu-mahmoud commented 4 years ago

Can some one please write a full guide from Null for manual installion for this plugin? I cloned this project and updated the SDK of version 2019.3.1 then rebuild it both Debug and Release => I used the Installation.md .. the solution builded without any error after that i created the nuget, then i tried to add it using extension manager in Reshaper but it didn't worked .. i tried also to copy the "ReSharper.Exceptional.dll" in AppData under DotFiles => image but it didn't worked also ...

Can someone please help to install this plugin manual?

ManticSic commented 4 years ago
  1. clone the repo
  2. cd ./build
  3. run 00_RestorePackages.bat
  4. run 01_Build.bat
  5. run 02_CreatePackages.bat. No you find a new package in ./build/Packages
  6. Open Visual Studio
  7. Open ReSharper Extension Manager
  8. Open Options
  9. Add a new Package Source
    • Name: e. g. "Exceptional Local"
    • Source: C:/path/to/ExceptionalReSharper/build/Packages
  10. Save
  11. Now you should find your new Version in the Extension Manager

I will write an updated Guide when I finished the build process for the nightly build (I hope I will get done in the next hours)

hhu-mahmoud commented 4 years ago

@ManticSic at first Thanks for all your efforts.

I have done all what you wrote + I updated the SDK

Steps: 1,2 and 3 gone without any problem but the build not ..

I changed at first the version in "ExceptionalDevs.Exceptional.nuspec" image

then i changed the version also in "AssemblyInfo.cs" image

after that I cleanded the solution and Build it in Visual studio as "Release", then i ran "00_RestorePackages.bat", otherwise i did it also in Visual Studio image

after that i tried to build the project as you said using "01_Build.bat" but i got Errors :

image

but i think this build using "01_Build.bat" is not neccessry if i did that in Visual studio and it was everything ok.

then i created the package using "02_CreatePackages.bat"

image

and then i linked it in the resharper extension manager in visual studio and then i restarted the visaul studio but it didn't work as you see in the pic:

image

my Resharper version is the same of the SDK version

image

do you have any idea? where is the problem?

ManticSic commented 4 years ago

I changed at first the version in "ExceptionalDevs.Exceptional.nuspec"

Thats right! Today I updated the *.nuspec file so the recorded version is hiher than the last published one, so this step will not longer be necessary.

then i changed the version also in "AssemblyInfo.cs"

It seems this entry wasn't updated some releases, thanks for that hint!

after that I cleanded the solution and Build it in Visual studio as "Release", then i ran "00_RestorePackages.bat", otherwise i did it also in Visual Studio image

00_RestorePackages.bat only restores the dependencies. AFAIK VS will do it automatically, if a dependency is not available. But when you culd already build the project in VS everything is fine.

after that i tried to build the project as you said using "01_Build.bat" but i got Errors :

I think the msbuild entry in your environment variables are outdated and VS uses a newer one. 01_build.bat only calls msbuild to rebuild the solution with the Release configuration, you can do this also in VS.

do you have any idea? where is the problem?

02_CreatePackages.bat should create a packaed named ExceptionalDevs.Exceptional.0.22.0.0.nupkg, does your directory containing this file?

hhu-mahmoud commented 4 years ago

@ManticSic

02_CreatePackages.bat should create a packaed named ExceptionalDevs.Exceptional.0.22.0.0.nupkg, does your directory containing this file?

Yes it created normally

image

I'm wondering if i did something wrong or if there is something changed in Resharper 2019.3.1?

ManticSic commented 4 years ago

Is an older version of Exceptional already installed? If yes: please uninstall it first.

Currently I'm wrting an updated guide, check it out. Maybe i missed something.

hhu-mahmoud commented 4 years ago

@ManticSic

Is an older version of Exceptional already installed? If yes: please uninstall it first. Currently I'm wrting an updated guide, check it out. Maybe i missed something.

Finally done, thank you for the hint. I removed everything old under those folders:

maybe you can write those steps as hint in the guide..

C:\Users\ {user}\AppData\Local\JetBrains\plugins C:\Users\ {user}\AppData\Local\NuGet\Cache

after restarting the VS, i was able to find this version under the "Extension Manager" and i was able to install it. After install i restarted the vs and it works fine! Thanks 👍

by the way: i add to wave version the old values wave: [193.0.0] but i don't think it would make a difference, cus it dosn't workd at first as the old versions were there!

ManticSic commented 4 years ago

I added your solution to the new guide. I will finish the guide the following days. If you have some other suggestions feel free to outtell them.

AFAIK [193.0.0] works only with R#2019.3.0, but [193] should work with all R# 2019.3.x. Thats what I my noticed but I'm not sure if thats entirely true. But I'm not sure if thats fully true.

hhu-mahmoud commented 4 years ago

AFAIK [193.0.0] works only with R#2019.3.0, but [193] should work with all R# 2019.3.x. Thats what I my noticed but I'm not sure if thats entirely true. But I'm not sure if thats fully true.

It works fine also with [193.0.0] .. I think it dosen't work with 2019.3.1 cus of the SDK!! the SDK was 2019.3.0 so i updated it and everything is okay!