christianhelle / apiclientcodegen

A collection of Visual Studio custom tool code generators for Swagger / OpenAPI specification files
http://bit.ly/restapicodegen
GNU General Public License v3.0
177 stars 23 forks source link

Bad kiota installation detection #775

Closed Hiller closed 5 months ago

Hiller commented 8 months ago

According to https://github.com/christianhelle/apiclientcodegen/blob/master/src/Core/ApiClientCodeGen.Core/Installer/DependencyInstaller.cs you are always starting kiota installation and detect whether it's installed by presence in error output SINGLE QUOTED tool ID ('microsoft.openapi.kiota') while dotnet is outputing it DOUBLE QUOTED. (Most probably it's a dotnet localization issue) I guess the best way to detect whether kiota is installed by checking its version running kiota --version if kiota is installed it will succeed and return version if case of failure you can initiate installation.

christianhelle commented 8 months ago

@Hiller Thanks for taking the time to report this

That's a good idea to just check the version, thanks for suggesting it. I will try it out