diff --git a/CHANGELOG.md b/CHANGELOG.md index 90b48b1371..26c7973995 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,6 +17,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Fixed cyclic dependencies in generated Go code. [#2834](https://github.com/microsoft/kiota/issues/2834) - Fixed a bug where default output folder is created on plugin edit and generate commands. [#5510](https://github.com/microsoft/kiota/issues/5429) - Changed GeneratedCode attribute applied when generating CSharp to only include the major version of Kiota. [#5489](https://github.com/microsoft/kiota/issues/5489) +- Fixed genarating CSharp client displays clean hint regardless of whether --clean-output is already passed [#5576](https://github.com/microsoft/kiota/issues/5576) ## [1.19.0] - 2024-10-03 diff --git a/src/kiota/Handlers/KiotaGenerateCommandHandler.cs b/src/kiota/Handlers/KiotaGenerateCommandHandler.cs index d44c035fdf..9a429501d0 100644 --- a/src/kiota/Handlers/KiotaGenerateCommandHandler.cs +++ b/src/kiota/Handlers/KiotaGenerateCommandHandler.cs @@ -141,7 +141,8 @@ public override async Task InvokeAsync(InvocationContext context) else { DisplaySuccess("Generation skipped as no changes were detected"); - DisplayCleanHint("generate"); + if (!cleanOutput) + DisplayCleanHint("generate"); } var manifestResult = await builder.GetApiManifestDetailsAsync(true, cancellationToken).ConfigureAwait(false); var manifestPath = manifestResult is null ? string.Empty : Configuration.Generation.ApiManifestPath; diff --git a/src/kiota/Handlers/KiotaUpdateCommandHandler.cs b/src/kiota/Handlers/KiotaUpdateCommandHandler.cs index fe1a1516a8..8b94e79bfc 100644 --- a/src/kiota/Handlers/KiotaUpdateCommandHandler.cs +++ b/src/kiota/Handlers/KiotaUpdateCommandHandler.cs @@ -69,7 +69,7 @@ public override async Task InvokeAsync(InvocationContext context) DisplaySuccess($"Update of {locks.Length} clients completed successfully"); foreach (var configuration in configurations) DisplayInfoHint(configuration.Language, configuration.OpenAPIFilePath, string.Empty); - if (Array.Exists(results, static x => x)) + if (Array.Exists(results, static x => x) && !cleanOutput) DisplayCleanHint("update"); return 0; }