Skip to content

Commit

Permalink
Updated code changes
Browse files Browse the repository at this point in the history
  • Loading branch information
ragavareddychalapala committed Feb 6, 2025
1 parent 5d40c8d commit fcb2fff
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
3 changes: 2 additions & 1 deletion src/ArtifactoryUploader/PackageUploader.cs
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,8 @@ public static async Task UploadPackageToArtifactory(CommonAppSettings appSetting
// set the error code
if (uploaderKpiData.PackagesNotUploadedDueToError > 0 || uploaderKpiData.PackagesNotExistingInRemoteCache > 0)
{
Environment.ExitCode = 2;
EnvironmentHelper environmentHelper = new EnvironmentHelper();
environmentHelper.CallEnvironmentExit(2);
Logger.Debug("Setting ExitCode to 2");
}
}
Expand Down
8 changes: 4 additions & 4 deletions src/LCT.Common/CommonHelper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -157,8 +157,8 @@ public static void WriteComponentsWithoutDownloadURLToKpi(List<ComparisonBomData
if (componentInfo.Count > 0 || lstReleaseNotCreated.Count > 0)
{
Logger.Logger.Log(null, Level.Alert, "Action Item required by the user:\n", null);
PipelineArtifactUploader.UploadArtifacts();
Environment.ExitCode = 2;
EnvironmentHelper environmentHelper = new EnvironmentHelper();
environmentHelper.CallEnvironmentExit(2);
}

if (componentInfo.Count > 0)
Expand Down Expand Up @@ -204,8 +204,8 @@ public static void WriteComponentsNotLinkedListInConsole(List<Components> compon

if (components.Count > 0)
{
PipelineArtifactUploader.UploadArtifacts();
Environment.ExitCode = 2;
EnvironmentHelper environmentHelper = new EnvironmentHelper();
environmentHelper.CallEnvironmentExit(2);
Logger.Logger.Log(null, Level.Alert, "* Components Not linked to project :", null);
Logger.Logger.Log(null, Level.Alert, " Can be linked manually OR Check the Logs AND RE-Run", null);
Logger.Logger.Log(null, Level.Alert, $"{"=",5}{string.Join("", Enumerable.Repeat("=", 98)),5}", null);
Expand Down

0 comments on commit fcb2fff

Please sign in to comment.