LeXtudio.Metadata.Mutable 0.9.5

Prefix Reserved
dotnet add package LeXtudio.Metadata.Mutable --version 0.9.5
                    
NuGet\Install-Package LeXtudio.Metadata.Mutable -Version 0.9.5
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="LeXtudio.Metadata.Mutable" Version="0.9.5" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="LeXtudio.Metadata.Mutable" Version="0.9.5" />
                    
Directory.Packages.props
<PackageReference Include="LeXtudio.Metadata.Mutable" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add LeXtudio.Metadata.Mutable --version 0.9.5
                    
#r "nuget: LeXtudio.Metadata.Mutable, 0.9.5"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package LeXtudio.Metadata.Mutable@0.9.5
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=LeXtudio.Metadata.Mutable&version=0.9.5
                    
Install as a Cake Addin
#tool nuget:?package=LeXtudio.Metadata.Mutable&version=0.9.5
                    
Install as a Cake Tool

AssemblyTools

LeXtudio.Metadata.Mutable — a small, reusable library for reading, mutating, and writing .NET assembly metadata and IL. This project consolidates mutable metadata/IL model code so tools like Obfuscar and other consumers can reuse a single, well-tested implementation.

Overview

  • Purpose: Provide a mutable object model for metadata and method bodies plus reader/writer implementations built on System.Reflection.Metadata.
  • Primary project: src/LeXtudio.Metadata.Mutable.
  • Supported TFMs: net8.0 (primary) and net462 (legacy compatibility).

Key features

  • Mutable metadata and IL model (types, methods, fields, instructions).
  • MutableAssemblyReader / MutableAssemblyWriter for PE/metadata read/write.
  • Designed for reuse across multiple tooling projects; lightweight compatibility shims are provided in Support.
  • Tests demonstrating round-trip behavior are included.

Getting started

Add the NuGet package from nuget.org (preferred):

dotnet add <your-project>.csproj package LeXtudio.Metadata.Mutable

If you need to test locally before publishing, pack the library and add the local folder as a package source:

dotnet pack src/LeXtudio.Metadata.Mutable/LeXtudio.Metadata.Mutable.csproj -c Release

dotnet nuget add source "src\LeXtudio.Metadata.Mutable\bin\Release" -n local-pkgs

dotnet add <your-project>.csproj package LeXtudio.Metadata.Mutable --source local-pkgs

Build the library (example, net8.0):

dotnet build src/LeXtudio.Metadata.Mutable/LeXtudio.Metadata.Mutable.csproj -f net8.0

Run the tests:

dotnet test tests/LeXtudio.Metadata.Mutable.Tests/LeXtudio.Metadata.Mutable.Tests.csproj

Usage

Documentation

Design notes and rationale: docs/design.md

Supported Target Frameworks

  • net8.0 (primary)
  • net462 (legacy compatibility)

Note: Some tests exercise net9.0 features and are located under the tests folder.

Contributing

  • Fork, implement changes in a feature branch, and open a pull request.
  • Run the relevant tests locally (dotnet test ...) and include tests for new behavior.
  • Keep changes focused and add documentation when you change public APIs.

License

This repository is licensed under the MIT License — see LICENSE.

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  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 Framework net462 is compatible.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 was computed.  net481 was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

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.9.5 24 5/1/2026
0.9.4 37 4/30/2026
0.9.3 30 4/30/2026
0.9.2 40 4/29/2026
0.9.1 35 4/29/2026
0.9.0 52 4/29/2026