KageKirin.ILRepack.Tool.MSBuild.Task
0.3.5
dotnet add package KageKirin.ILRepack.Tool.MSBuild.Task --version 0.3.5
NuGet\Install-Package KageKirin.ILRepack.Tool.MSBuild.Task -Version 0.3.5
<PackageReference Include="KageKirin.ILRepack.Tool.MSBuild.Task" Version="0.3.5"> <PrivateAssets>all</PrivateAssets> <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets> </PackageReference>
<PackageVersion Include="KageKirin.ILRepack.Tool.MSBuild.Task" Version="0.3.5" />
<PackageReference Include="KageKirin.ILRepack.Tool.MSBuild.Task"> <PrivateAssets>all</PrivateAssets> <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets> </PackageReference>
paket add KageKirin.ILRepack.Tool.MSBuild.Task --version 0.3.5
#r "nuget: KageKirin.ILRepack.Tool.MSBuild.Task, 0.3.5"
#:package KageKirin.ILRepack.Tool.MSBuild.Task@0.3.5
#addin nuget:?package=KageKirin.ILRepack.Tool.MSBuild.Task&version=0.3.5
#tool nuget:?package=KageKirin.ILRepack.Tool.MSBuild.Task&version=0.3.5
<img src="Icon.png" alt="ILRepack.MSBuild.Task icon" height="200" width="200" align="right" />
ILRepack.MSBuild.Task
KageKirin.ILRepack.MSBuild.Task
contains tasks for MSBuild to run ILRepack
over a freshly compiled assembly,
in order to infuse it with select IL code of its dependencies.
📦 Package information
KageKirin.ILRepack.Tool.MSBuild.Task
This is the tool variant. It requires having ILRepack installed.
KageKirin.ILRepack.Lib.MSBuild.Task
This is the lib variant. It's standalone and ILRepack.Lib has been merged into it.
🔧 Installation
dotnet add package KageKirin.ILRepack.Tool.MSBuild.Task ## tool version
dotnet add package KageKirin.ILRepack.Lib.MSBuild.Task ## lib version
📦 Package reference
<Project>
<ItemGroup>
<PackageReference Include="KageKirin.ILRepack.Tool.MSBuild.Task" Version="0.3.0" />
<PackageReference Include="KageKirin.ILRepack.Lib.MSBuild.Task" Version="0.3.0" />
</ItemGroup>
</Project>
⚙️ Configuration
ILRepack.Tool.MSBuild.Task
and ILRepack.Lib.MSBuild.Task
can be used interchangeably as both use the same properties and items.
Therefore it is not recommended to use both in the same project.
The task can be used in 2 manners:
- using the default target that relies on configuration only
- use=ing a custom target that calls the
ILRepack
task.
Configuration only default target
Global configuration goes into a solution-wide Directory.Build.props
as usual,
per-project configuration can go into each .csproj
project file, or preferrably
into ILRepack.Configuration.props
.
I do recommend using a per-project ILRepack.Configuration.props
residing next to the project.
Custom target using the ILRepack
task
Custom targets ought to be handled per-project and go into a ILRepack.targets
file residing next to the project.
Options and description
The ILRepack
exposes a number of parameters that have their equivalent in the form of ILRepackXXX
properties or items
(which then get internally forward to the aforementioned task).
Most of those parameters/properties correspond directly to the command line arguments that ILRepack.exe
can take, respectively,
to the fields of ILRepacking.RepackOptions
used internally by the ILRepack.dll
library.
Properties
For the record, properties go into a (read one or more) <PropertyGroup>
container.
<Project>
<PropertyGroup>
</PropertyGroup>
</Project>
Boolean flags
<ILRepackProperty> |
ILRepack task parameter |
corresponding ILRepack.exe argument |
summary |
---|---|---|---|
<ILRepackParallel> |
Parallel |
/parallel |
use as many CPUs as possible to merge the assemblies |
<ILRepackDebugInfo> |
DebugInfo |
/ndebug (when omitted) |
enables symbol file generation. explcitly set to false to disable default behaviour. |
<ILRepackLogVerbose> |
LogVerbose |
/verbose |
more detailed logging |
<ILRepackInternalize> |
Internalize |
/internalize |
make all types except in the first assembly 'internal'. Types in the transitive closure of public API remain public. |
<ILRepackRenameInternalized> |
RenameInternalized |
/renameinternalized |
rename each internalized type to a new unique name |
<ILRepackAllowWildCards> |
AllowWildCards |
/wildcards |
allows (and resolves) file wildcards (e.g. *.dll) in input assemblies |
<ILRepackDelaySign> |
DelaySign |
/delaysign |
set the key, but don't sign the assembly |
<ILRepackExcludeInternalizeSerializable> |
ExcludeInternalizeSerializable |
/excludeinternalizeserializable |
do not internalize types marked as Serializable |
<ILRepackUnionMerge> |
UnionMerge |
/union |
merges types with identical names into one |
<ILRepackAllowAllDuplicateTypes> |
AllowAllDuplicateTypes |
/allowdup |
if no other /allowdup arguments specified, allow all duplicate types. (see <ILRepackAllowDuplicateTypes> below for more information) |
<ILRepackAllowDuplicateResources> |
AllowDuplicateResources |
/allowduplicateresources |
allows to duplicate resources in output assembly (by default they're ignored) |
<ILRepackNoRepackRes> |
NoRepackRes |
/noRepackRes |
do not add the resource 'ILRepack.List' with all merged assembly names |
<ILRepackCopyAttributes> |
CopyAttributes |
/copyattrs |
copy assembly attributes (by default only the primary assembly attributes are copied) |
<ILRepackAllowMultipleAssemblyLevelAttributes> |
AllowMultipleAssemblyLevelAttributes |
/allowMultiple |
when copyattrs is specified, allows multiple attributes (if type allows) |
<ILRepackKeepOtherVersionReferences> |
KeepOtherVersionReferences |
/keepotherversionreferences |
take reference assembly version into account when removing references |
<ILRepackPreserveTimestamp> |
PreserveTimestamp |
/preservetimestamp |
preserve original file PE timestamp |
<ILRepackSkipConfigMerge> |
SkipConfigMerge |
/skipconfig |
skips merging config files |
<ILRepackMergeIlLinkerFiles> |
MergeIlLinkerFiles |
/illink |
merge IL Linker files |
<ILRepackXmlDocumentation> |
XmlDocumentation |
/xmldocs |
merges XML documentation as well |
<ILRepackAllowZeroPeKind> |
AllowZeroPeKind |
/zeropekind |
allows assemblies with Zero PeKind (but obviously only IL will get merged) |
<ILRepackLineIndexation> |
LineIndexation |
/index |
stores file:line debug information as type/method attributes (requires PDB) |
<ILRepackPauseBeforeExit> |
PauseBeforeExit |
/pause |
pause execution once completed, good for debugging, don't use for CI/CD |
<ILRepackClosed> |
Closed |
/closed |
NOT IMPLEMENTED |
Single string values
<ILRepackProperty> |
ILRepack task parameter |
corresponding ILRepack.exe argument |
summary | ||
---|---|---|---|---|---|
<ILRepackVersion> |
Version |
/ver:M.X.Y.Z |
target assembly version | ||
<ILRepackTargetKind> |
TargetKind |
/target:kind |
target assembly kind [library | exe | winexe], default is same as primary assembly |
<ILRepackTargetPlatformDirectory> |
TargetPlatformDirectory |
/targetplatform:P (first part of P) |
specify target platform path | ||
<ILRepackTargetPlatformVersion> |
TargetPlatformVersion |
/targetplatform:P (second part of P) |
specify target platform version (v1, v1.1, v2, v4 supported) |
Integer values
<ILRepackProperty> |
ILRepack task parameter |
corresponding ILRepack.exe argument |
summary |
---|---|---|---|
<ILRepackFileAlignment> |
FileAlignment |
/align |
NOT IMPLEMENTED |
<ILRepackTimeout> |
Timeout |
timeout to end task in seconds. This is a special value that allows to terminate the ILRepack task after the specified time to avoid endless loops eating up precious CI time. |
Items
For the record, items go into a (read one or more) <ItemGroup>
container.
<Project>
<ItemGroup>
</ItemGroup>
</Project>
Required item inputs
<ILRepackItem> |
ILRepack task parameter |
corresponding ILRepack.exe argument |
summary |
---|---|---|---|
<ILRepackOutputFile> |
OutputFile |
/out:<path> |
target assembly path, symbol/config/doc files will be written here as well |
<ILRepackInputAssemblies> |
InputAssemblies |
paths to input assemblies in the following order: <br/> - primary assembly: gives the name, version to the merged one<br/> - other assemblies: other assemblies to merge with the primary one |
Further item inputs
<ILRepackItem> |
ILRepack task parameter |
corresponding ILRepack.exe argument |
summary |
---|---|---|---|
<ILRepackLogFile> |
LogFile |
/log:<logfile> |
enable logging to the given file (default is disabled) |
<ILRepackLibraryPaths> |
LibraryPaths |
/lib:<path> |
path(s) to search directories to resolve referenced assemblies (can be specified multiple times). <br/>If you get 'unable to resolve assembly' errors specify a path to a directory where the assembly can be found. |
<ILRepackInternalizeExclude> |
InternalizeExclude |
/internalize:<exclude_file> |
each item is either a regex or a full type name not to internalize, or an assembly name not to internalize (.dll extension optional). <br/>Internally, each item is written line-by-line into a ILRepack.not file that gets passed as |
<ILRepackInternalizeAssemblies> |
InternalizeAssemblies |
/internalizeassembly:<path> |
internalize a specific assembly name (no extension). <br/>May be specified more than once (one per assembly to internalize). <br/>If specified, no need to also specify /internalize . |
<ILRepackKeyFile> |
KeyFile |
/keyfile:<path> |
keyfile to sign the output assembly |
<ILRepackKeyContainer> |
KeyContainer |
/keycontainer:<c> |
key container |
<ILRepackAllowedDuplicateTypes> |
AllowedDuplicateTypes |
/allowdup:Type |
keep duplicates of the specified type, may be specified more than once |
<ILRepackRepackDropAttributes> |
DropAttributes |
/repackdrop:RepackDropAttribute |
allows dropping members denoted by this attribute name when merging |
<ILRepackImportAttributeAssemblies> |
ImportAttributeAssemblies |
/attr:<path> |
take assembly attributes from the given assembly file |
<ILRepackFilterAssemblies> |
FilterAssemblies |
optional list of assemblies (partial names or regex) to keep among all the input assemblies. Non-matching ones are discarded from the inputs. <br/>The reason for this is that filtering the sometimes many input assemblies using only MSBuild functions is rather complex, whereas this simple list simplifies the process extremely. |
🤝 Collaborate with My Project
Please refer to COLLABORATION.md.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
.NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
.NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
.NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
MonoAndroid | monoandroid was computed. |
MonoMac | monomac was computed. |
MonoTouch | monotouch was computed. |
Tizen | tizen40 was computed. tizen60 was computed. |
Xamarin.iOS | xamarinios was computed. |
Xamarin.Mac | xamarinmac was computed. |
Xamarin.TVOS | xamarintvos was computed. |
Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETStandard 2.0
- No dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last Updated |
---|---|---|
0.3.5 | 10 | 8/3/2025 |
0.3.4 | 10 | 8/2/2025 |
0.3.3 | 16 | 8/2/2025 |
0.3.2 | 66 | 8/1/2025 |
0.3.1 | 64 | 8/1/2025 |
0.3.0 | 83 | 7/31/2025 |
0.2.8 | 85 | 7/31/2025 |
0.2.7 | 87 | 7/31/2025 |
0.2.6 | 81 | 7/31/2025 |
0.2.5 | 83 | 7/31/2025 |
0.2.4 | 87 | 7/30/2025 |
0.2.3 | 84 | 7/30/2025 |
0.2.2 | 83 | 7/30/2025 |
0.2.1 | 82 | 7/30/2025 |
0.2.0 | 83 | 7/29/2025 |
0.1.14 | 91 | 7/29/2025 |
0.1.13 | 82 | 7/29/2025 |
0.1.12 | 85 | 7/29/2025 |
0.1.11 | 84 | 7/29/2025 |
0.1.10 | 83 | 7/29/2025 |
0.1.9 | 82 | 7/29/2025 |
0.1.8 | 82 | 7/29/2025 |
0.1.7 | 83 | 7/29/2025 |
0.1.6 | 86 | 7/29/2025 |
0.1.5 | 484 | 7/22/2025 |
0.1.4 | 484 | 7/22/2025 |
0.1.3 | 481 | 7/22/2025 |
0.1.2 | 486 | 7/22/2025 |
0.1.1 | 468 | 7/22/2025 |
0.1.0 | 473 | 7/22/2025 |
0.0.36 | 442 | 7/21/2025 |
0.0.35 | 429 | 7/21/2025 |
0.0.34 | 430 | 7/21/2025 |
0.0.33 | 430 | 7/21/2025 |
0.0.32 | 429 | 7/21/2025 |
0.0.31 | 431 | 7/21/2025 |
0.0.30 | 429 | 7/21/2025 |
0.0.29 | 431 | 7/21/2025 |
0.0.28 | 429 | 7/21/2025 |
0.0.27 | 434 | 7/21/2025 |
0.0.26 | 358 | 7/21/2025 |
0.0.23 | 105 | 7/18/2025 |
0.0.22 | 101 | 7/18/2025 |
0.0.21 | 100 | 7/18/2025 |
0.0.20 | 96 | 7/18/2025 |
0.0.19 | 96 | 7/18/2025 |
0.0.18 | 110 | 7/17/2025 |
0.0.17 | 110 | 7/17/2025 |
0.0.16 | 106 | 7/17/2025 |
0.0.15 | 111 | 7/17/2025 |
0.0.14 | 108 | 7/17/2025 |
0.0.13 | 111 | 7/17/2025 |
0.0.12 | 105 | 7/17/2025 |
0.0.11 | 110 | 7/16/2025 |
0.0.10 | 110 | 7/16/2025 |
0.0.9 | 105 | 7/16/2025 |
0.0.8 | 109 | 7/16/2025 |
0.0.7 | 107 | 7/16/2025 |
0.0.6 | 111 | 7/16/2025 |
0.0.5 | 114 | 7/16/2025 |
0.0.4 | 108 | 7/16/2025 |
0.0.3 | 111 | 7/15/2025 |
0.0.2 | 111 | 7/15/2025 |
0.0.1 | 115 | 7/15/2025 |
CHANGELOG.md