# Issues with Resharper Tool

**URL:** https://community.revolutionarygamesstudio.com/t/issues-with-resharper-tool/4158
**Category:** Development Help
**Created:** [January 5, 2022, 5:45am UTC](https://community.revolutionarygamesstudio.com/t/issues-with-resharper-tool/4158 "2022-01-05T05:45:29Z")
**Posts on this page:** 10
**Page:** 1

<div class="post-metadata">

### Author: ![Evolution4Weak](https://thrivecommunity-cdn.b-cdn.net/user_avatar/community.revolutionarygamesstudio.com/evolution4weak/32/11005_2.png) [@Evolution4Weak](https://community.revolutionarygamesstudio.com/u/Evolution4Weak)
#### Post date: [January 5, 2022, 5:45am UTC](https://community.revolutionarygamesstudio.com/t/issues-with-resharper-tool/4158/1 "2022-01-05T05:45:30Z")

</div>

# Issue Description

I been working on a fork of thrive to eventaually get pulled into the main branch and i was trying to use the `check_formatting.rb` tool to make sure everything is right but when i run it i get an error when it tries to restore the dotnet tool because it not compatible net60 and only supported netcoreapp3.1, i did install .net 6.0 for a unrelated project but i am not sure how to get the tool use the right version as i did intall .net core 3.1 but that still did not help.

# Your code

I don’t think it’s relevant

# Extra error information

> **Actual Error Message:**
>
> ```auto
> Restoring dotnet tools to make sure they are up to date
> \AppData\Local\Temp\l23mktj3.mch\restore.csproj : error NU1202: Package JetBrains.ReSharper.GlobalTools 2021.3.1 is not compatible with net60 (.NETFramework,Version=v6.0) / any. Package JetBrains.ReSharper.GlobalTools 2021.3.1 supports: netcoreapp3.1 (.NETCoreApp,Version=v3.1) / any
> 
> Package "jetbrains.resharper.globaltools" failed to restore, due to Microsoft.DotNet.ToolPackage.ToolPackageException: The tool package could not be restored.
> at Microsoft.DotNet.Tools.Tool.Install.ProjectRestorer.Restore(FilePath project, PackageLocation packageLocation, String verbosity)
> at Microsoft.DotNet.ToolPackage.ToolPackageInstaller.InstallPackageToExternalManagedLocation(PackageLocation packageLocation, PackageId packageId, VersionRange versionRange, String targetFramework, String verbosity)
> at Microsoft.DotNet.Tools.Tool.Restore.ToolRestoreCommand.InstallPackages(ToolManifestPackage package, Nullable`1 configFile)
> 
> Restore failed.
> 
> ERROR: Running command failed (if you try running this manually you need to make sure that all the comma separated parts are quoted if they aren't whole words): dotnet, tool, restore
> Stack trace for error:
> /RubySetupSystem/RubyCommon.rb:240:in `runOpen3Checked'
> /check_formatting.rb:233:in `block in install_dotnet_tools'
> /check_formatting.rb:224:in `synchronize'
> /check_formatting.rb:224:in `install_dotnet_tools'
> /check_formatting.rb:732:in `run_inspect_code'
> /check_formatting.rb:954:in `block in <main>'
> /check_formatting.rb:972:in `block (2 levels) in <main>'
> 
> ```

---

<div class="post-metadata">

### Author: ![hhyyrylainen](https://thrivecommunity-cdn.b-cdn.net/user_avatar/community.revolutionarygamesstudio.com/hhyyrylainen/32/32_2.png) [@hhyyrylainen](https://community.revolutionarygamesstudio.com/u/hhyyrylainen)
#### Post date: [January 5, 2022, 7:46am UTC](https://community.revolutionarygamesstudio.com/t/issues-with-resharper-tool/4158/2 "2022-01-05T07:46:30Z")

</div>

Are the SDKs properly installed?

I get the following:

```auto
$ dotnet --list-sdks
3.1.118 [/usr/lib64/dotnet/sdk]
5.0.206 [/usr/lib64/dotnet/sdk]
6.0.100 [/usr/lib64/dotnet/sdk]

```

Also just having sdk version 5 should be enough (at least on Linux) as the CI containers manage to install the tools just fine with only that version installed.

---

<div class="post-metadata">

### Author: ![Evolution4Weak](https://thrivecommunity-cdn.b-cdn.net/user_avatar/community.revolutionarygamesstudio.com/evolution4weak/32/11005_2.png) [@Evolution4Weak](https://community.revolutionarygamesstudio.com/u/Evolution4Weak)
#### Post date: [January 5, 2022, 4:59pm UTC](https://community.revolutionarygamesstudio.com/t/issues-with-resharper-tool/4158/3 "2022-01-05T16:59:11Z")

</div>

Yeah it looks like it is:

```auto
2.1.202 [C:\Program Files\dotnet\sdk]
2.1.504 [C:\Program Files\dotnet\sdk]
2.1.505 [C:\Program Files\dotnet\sdk]
2.1.516 [C:\Program Files\dotnet\sdk]
3.1.402 [C:\Program Files\dotnet\sdk]
3.1.416 [C:\Program Files\dotnet\sdk]
6.0.101 [C:\Program Files\dotnet\sdk]

```

---

<div class="post-metadata">

### Author: ![hhyyrylainen](https://thrivecommunity-cdn.b-cdn.net/user_avatar/community.revolutionarygamesstudio.com/hhyyrylainen/32/32_2.png) [@hhyyrylainen](https://community.revolutionarygamesstudio.com/u/hhyyrylainen)
#### Post date: [January 5, 2022, 5:07pm UTC](https://community.revolutionarygamesstudio.com/t/issues-with-resharper-tool/4158/4 "2022-01-05T17:07:13Z")

</div>

It looks like you don’t have version 5, which might be the exactly needed one.

---

<div class="post-metadata">

### Author: ![Evolution4Weak](https://thrivecommunity-cdn.b-cdn.net/user_avatar/community.revolutionarygamesstudio.com/evolution4weak/32/11005_2.png) [@Evolution4Weak](https://community.revolutionarygamesstudio.com/u/Evolution4Weak)
#### Post date: [January 5, 2022, 5:09pm UTC](https://community.revolutionarygamesstudio.com/t/issues-with-resharper-tool/4158/5 "2022-01-05T17:09:36Z")

</div>

I just installed it and it still gives the same error

```auto
2.1.202 [C:\Program Files\dotnet\sdk]
2.1.504 [C:\Program Files\dotnet\sdk]
2.1.505 [C:\Program Files\dotnet\sdk]
2.1.516 [C:\Program Files\dotnet\sdk]
3.1.402 [C:\Program Files\dotnet\sdk]
3.1.416 [C:\Program Files\dotnet\sdk]
5.0.404 [C:\Program Files\dotnet\sdk]
6.0.101 [C:\Program Files\dotnet\sdk]

```

```auto
error NU1202: Package JetBrains.ReSharper.GlobalTools 2021.3.1 is not compatible with net60 (.NETFramework,Version=v6.0) / any. Package JetBrains.ReSharper.GlobalTools 2021.3.1 supports: netcoreapp3.1 (.NETCoreApp,Version=v3.1) / any

```

---

<div class="post-metadata">

### Author: ![hhyyrylainen](https://thrivecommunity-cdn.b-cdn.net/user_avatar/community.revolutionarygamesstudio.com/hhyyrylainen/32/32_2.png) [@hhyyrylainen](https://community.revolutionarygamesstudio.com/u/hhyyrylainen)
#### Post date: [January 5, 2022, 5:39pm UTC](https://community.revolutionarygamesstudio.com/t/issues-with-resharper-tool/4158/6 "2022-01-05T17:39:01Z")

</div>

Well all I know is that the command listed here: [NuGet Gallery | JetBrains.ReSharper.GlobalTools 2021.3.2](https://www.nuget.org/packages/JetBrains.ReSharper.GlobalTools/) should work and that jetbrains has some documentation of their own about installing the tools here: [ReSharper command line tools | ReSharper](https://www.jetbrains.com/help/resharper/ReSharper_Command_Line_Tools.html)

---

<div class="post-metadata">

### Author: ![Evolution4Weak](https://thrivecommunity-cdn.b-cdn.net/user_avatar/community.revolutionarygamesstudio.com/evolution4weak/32/11005_2.png) [@Evolution4Weak](https://community.revolutionarygamesstudio.com/u/Evolution4Weak)
#### Post date: [January 5, 2022, 9:09pm UTC](https://community.revolutionarygamesstudio.com/t/issues-with-resharper-tool/4158/7 "2022-01-05T21:09:05Z")

</div>

I was eventually able to figure it out by creating a global.json file with the following content:

```auto
{
  "sdk": {
    "version": "3.1.100",
    "rollForward": "latestFeature"
  }
}

```

---

<div class="post-metadata">

### Author: ![hhyyrylainen](https://thrivecommunity-cdn.b-cdn.net/user_avatar/community.revolutionarygamesstudio.com/hhyyrylainen/32/32_2.png) [@hhyyrylainen](https://community.revolutionarygamesstudio.com/u/hhyyrylainen)
#### Post date: [January 6, 2022, 6:14am UTC](https://community.revolutionarygamesstudio.com/t/issues-with-resharper-tool/4158/8 "2022-01-06T06:14:26Z")

</div>

In the Thrive folder or somewhere else?  
I guess that file configures which .NET version to use when running the dotnet command?

---

<div class="post-metadata">

### Author: ![Evolution4Weak](https://thrivecommunity-cdn.b-cdn.net/user_avatar/community.revolutionarygamesstudio.com/evolution4weak/32/11005_2.png) [@Evolution4Weak](https://community.revolutionarygamesstudio.com/u/Evolution4Weak)
#### Post date: [January 6, 2022, 6:20am UTC](https://community.revolutionarygamesstudio.com/t/issues-with-resharper-tool/4158/9 "2022-01-06T06:20:59Z")

</div>

Yeah that what it does, i just made it in the thrive root folder

> **[global.json overview - .NET CLI](https://docs.microsoft.com/en-us/dotnet/core/tools/global-json?tabs=netcore3x)**
>
> Learn how to use the global.json file to set the .NET SDK version when running .NET CLI commands.

it works with the ‘check\_formatting.rb’ tool too

---

<div class="post-metadata">

### Author: ![hhyyrylainen](https://thrivecommunity-cdn.b-cdn.net/user_avatar/community.revolutionarygamesstudio.com/hhyyrylainen/32/32_2.png) [@hhyyrylainen](https://community.revolutionarygamesstudio.com/u/hhyyrylainen)
#### Post date: [January 7, 2022, 7:55am UTC](https://community.revolutionarygamesstudio.com/t/issues-with-resharper-tool/4158/10 "2022-01-07T07:55:57Z")

</div>

Should we then consider putting that kind of file in the main repo? Or perhaps we should wait and see if other people have the same issue.
