diff --git a/.github/workflows/Build.yml b/.github/workflows/Build.yml index 3918b90..37e4bf9 100644 --- a/.github/workflows/Build.yml +++ b/.github/workflows/Build.yml @@ -27,7 +27,5 @@ jobs: NugetApiUrl: ${{ secrets.NUGET_API_URL }} NugetApiKey: ${{ secrets.NUGET_API_KEY }} - # SignFile: ${{ secrets.SIGN_FILE }} - # SignPassword: ${{ secrets.SIGN_PASSWORD }} - SignFile: ${{ secrets.SIGN_FILE_AZURE }} - SignPassword: ${{ secrets.SIGN_PASSWORD_AZURE }} \ No newline at end of file + SignFile: ${{ secrets.SIGN_FILE }} + SignPassword: ${{ secrets.SIGN_PASSWORD }} \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 258cd60..5e1c8e8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). +## [1.9.1] / 2025-01-03 +### Updated +- Force to uninstall local `Tools` to remove cache when `.exe` is not found. (Fix: #79) + ## [1.9.0] / 2024-12-06 - 2024-12-19 ### Features - Enable sign files using `Azure Key Vault`. @@ -389,6 +393,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. - First Release [vNext]: ../../compare/1.0.0...HEAD +[1.9.1]: ../../compare/1.9.0...1.9.1 [1.9.0]: ../../compare/1.8.2...1.9.0 [1.8.2]: ../../compare/1.8.1...1.8.2 [1.8.1]: ../../compare/1.8.0...1.8.1 diff --git a/Directory.Build.props b/Directory.Build.props index 3af54d3..dbbf2ae 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -1,5 +1,5 @@ - 1.9.0 + 1.9.1 \ No newline at end of file diff --git a/ricaun.Nuke/Extensions/NuGetExtension.cs b/ricaun.Nuke/Extensions/NuGetExtension.cs index 3d40d82..2f297da 100644 --- a/ricaun.Nuke/Extensions/NuGetExtension.cs +++ b/ricaun.Nuke/Extensions/NuGetExtension.cs @@ -169,6 +169,7 @@ public static bool NugetSign(string packageFileName, string certPath, string cer { try { + Serilog.Log.Information($"NuGet sign: {packageFileName}"); NuGetTasks.NuGet( $"sign \"{packageFileName}\"" + $" -CertificatePath {certPath}" + diff --git a/ricaun.Nuke/Tools/AzureSignToolUtils.cs b/ricaun.Nuke/Tools/AzureSignToolUtils.cs index eeb8eb8..2f2e807 100644 --- a/ricaun.Nuke/Tools/AzureSignToolUtils.cs +++ b/ricaun.Nuke/Tools/AzureSignToolUtils.cs @@ -63,6 +63,18 @@ private static string PackageDownload(string packageId) return packageToolExeExists; } + try + { + // Force to uninstall to remove cache files if exists. + DotNetTasks.DotNetToolUninstall(x => x + .SetPackageName(packageId) + .SetToolInstallationPath(toolFolder) + .DisableProcessLogInvocation() + .DisableProcessLogOutput() + ); + } + catch { } + DotNetTasks.DotNetToolInstall(x => x .SetPackageName(packageId) .SetToolInstallationPath(toolFolder)