Comments (2)
Second example in the docs: https://github.com/brutaldev/StrongNameSigner#build-process
Example of targeting one package folder.
<Target Name="BeforeBuild">
<Exec ContinueOnError="false"
Command=""..\packages\Brutal.Dev.StrongNameSigner.3.1.1\build\StrongNameSigner.Console.exe" -in "..\packages\elmah.corelibrary.1.2.2"" />
</Target>
You can remove the other targets that are created in your project file that perform a full signing operation.
from strongnamesigner.
My project file looks like this (kept out unnecessary details):
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFrameworks>net481</TargetFrameworks>
....
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<DefineConstants>DEBUG;TRACE</DefineConstants>
</PropertyGroup>
....
<ItemGroup>
<PackageReference Include="Brutal.Dev.StrongNameSigner" Version="3.1.1" />
<PackageReference Include="Vestris.ResourceLib" Version="2.1.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>
<Target Name="SignResourceLib" BeforeTargets="ResolveAssemblyReferences" Condition=" '$(TargetDir)' != '' " Inputs="$(SolutionDir)bin\_packages\vestris.resourcelib\2.1.0\lib\net45\Vestris.ResourceLib.dll" Outputs="$(SolutionDir)bin\_signed\Vestris.ResourceLib.dll">
<Exec Command=""$(StrongNameSignerDirectory)StrongNameSigner.Console" -in "$(SolutionDir)bin\_packages\vestris.resourcelib\2.1.0\lib\net45" -out "$(SolutionDir)bin\_signed"" WorkingDirectory="$(SolutionDir)" />
</Target>
</Project>
The target is executed as expected and signs the Vetris.ResourceLib.dll. However, when I look at the build output, there is also another task being executed that seems to try to sign all DLLs in my entire tree. This is what I see in the output (verbosity level "Normal"):
Target StrongNameSignerTarget:
-- Starting Brutal Developer .NET Assembly Strong-Name Signer Task --
<a lot of assemblies from alll kinds of folders are "added for processing">
-- Finished Brutal Developer .NET Assembly Strong-Name Signer Task in 00:00:01.4505714 --
This StrongNameSignerTarget
is the target that is started automatically, and is not explicitly referenced in the project. @brutaldev How can I prevent this target to run?
from strongnamesigner.
Related Issues (20)
- Writing mixed-mode assemblies is not supported HOT 3
- Transitive dependencies from PackageReferences are not investigated/signed HOT 3
- Use NuGet package, but no automatic signing of assemblies HOT 2
- Virus Detected on Chrome when downloading StrongNameSigner_Setup.exe HOT 1
- SDK style probjects supported? HOT 4
- Failed to resolve assembly: 'mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' HOT 12
- Fixing unsigned references in signed assemblies when signing unsigned assemblies - unhandled case? HOT 5
- [Bug]: When the GUI comes across a "Unsupported PDB deleted bitset is not empty" it stops processing HOT 1
- [Feature Request]: convert the "Unsupported PDB deleted bitset is not empty" Error to a warning, so that the commandline app does not report errors HOT 2
- [Feature Request]: Can the Gui state what file has been used to sign a binary HOT 1
- [Bug]: If strongnamer is already processing a file, then do not throw an error when it tries to open it again due to parallel builds
- [Change Request]: Please change the column named `Signed` to be `StrongNamed` HOT 1
- [Feature Request]: Have a column called `DigCert` to show if this binary also has been digitally signed HOT 2
- [Bug]: Getting `Mono.Cecil.AssemblyResolutionException: Failed to resolve assembly: 'mscorlib, Version=4.0.0.0` for x86 project HOT 13
- Keyset does not exist error when using custom SNK generated from PFX file HOT 3
- Does not work with VS 2022 started with Admin rights targeting .net 4.8 framework HOT 9
- Can not get it to work with .NET Standard 2.0 Project and Nuget Packages Scrypt.NET and CSVTextFieldParser HOT 2
- Fails to ignore package dlls if %NUGET_PACKAGES% is set to a different format of path. HOT 2
- Failed to resolve System.IO.FileAccess HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from strongnamesigner.