This program converts the original .NET assembly, replacing all addition operations (OpCodes.Add
) with subtraction
operations (OpCodes.Sub
), using the Mono.Cecil library. The resulting assembly is
saved to the new path.
- AssemblyChanges - The main logic for working with CIL (Common Intermediate Language)
- ConsoleApplication - Simple console application with outputting the result of methods
- TestApplication - Application for testing basic logic using NUnit
Run from project root directory:
$ dotnet run --project ./AssemblyChanges/AssemblyChanges/AssemblyChanges.csproj -- pathToAssembly pathToNewDirectory
Run from build directory with assembly:
$ dotnet AssemblyChanges.dll -- pathToAssembly pathToNewDirectory
NOTE: when passing a file as the second argument (not a directory), then the resulting directory will be selected.