mirror of
https://github.com/brutaldev/StrongNameSigner.git
synced 2026-04-25 11:26:04 +03:00
[GH-ISSUE #96] Fails to ignore package dlls if %NUGET_PACKAGES% is set to a different format of path. #81
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @CZEMacLeod on GitHub (Jul 16, 2023).
Original GitHub issue: https://github.com/brutaldev/StrongNameSigner/issues/96
Originally assigned to: @brutaldev on GitHub.
If I globally set the environment variable
NUGET_PACKAGESto something likeS:\Packages*, the task does not ignore the DLLs from packages any more.*in my case having moved my packages to a DevDrive, or
C:\azp\packageson my azure devops build server.There is some code with hardcoded possible paths here
github.com/brutaldev/StrongNameSigner@4a96c7855e/src/Brutal.Dev.StrongNameSigner/AutomaticBuildTask.cs (L77)I think the base path for nuget packages should probably be a parameter or perhaps an itemgroup array that can be passed in, with a default value of
NUGET_PACKAGESif set...There is a property
RestorePackagesPathwhich can be set too which should probably be respected.This would allow a consumer to specify any additional directories etc. that are used as restore sources.
I think on new SDK projects, there is a property generated in
xxx.csproj.nuget.g.propswhich has all the package folders:NuGetPackageFoldersWould you consider a PR to implement this?
@CZEMacLeod commented on GitHub (Jul 16, 2023):
I also seem to have this path showing for a lot of assemblies which I think are the reference assemblies, but are not ignored:
C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Microsoft\Microsoft.NET.Build.Extensions\@brutaldev commented on GitHub (Aug 21, 2023):
@CZEMacLeod Will certainly accept a PR around this if you are willing to make the changes.
There is also the
globalPackagesFolderconfiguration that can be added to a NuGet.config file:NUGET_PACKAGESto processing paths.RestorePackagesPathand add to processing and/o probing paths.Microsoft.NET.Build.Extensionsto the ignore list.NuGetPackageFoldersproperties (if possible) to exclude SDK folders?