com.IvanMurzak.CodeExec.Roslyn
0.2.1
dotnet add package com.IvanMurzak.CodeExec.Roslyn --version 0.2.1
NuGet\Install-Package com.IvanMurzak.CodeExec.Roslyn -Version 0.2.1
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="com.IvanMurzak.CodeExec.Roslyn" Version="0.2.1" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="com.IvanMurzak.CodeExec.Roslyn" Version="0.2.1" />
<PackageReference Include="com.IvanMurzak.CodeExec.Roslyn" />
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 com.IvanMurzak.CodeExec.Roslyn --version 0.2.1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: com.IvanMurzak.CodeExec.Roslyn, 0.2.1"
#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 com.IvanMurzak.CodeExec.Roslyn@0.2.1
#: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=com.IvanMurzak.CodeExec.Roslyn&version=0.2.1
#tool nuget:?package=com.IvanMurzak.CodeExec.Roslyn&version=0.2.1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
Code-Exec for .NET
Run short C# snippets inside a live host process (game engines, editors, any .NET app). Built for AI agents: write only statements, add your own usings, declare types and functions; the last expression is the result; errors point at the snippet's own lines.
Two packages:
com.IvanMurzak.CodeExec— the runtime. No dependencies.netstandard2.0(Unity / Mono, .NET Framework) andnet8.0(each run in its own collectibleAssemblyLoadContext, unloaded afterwards).com.IvanMurzak.CodeExec.Roslyn— source-only: the compiler adapter compiles inside your project against yourMicrosoft.CodeAnalysis.CSharp(3.8 or newer). Add that package yourself.
var runner = new CodeRunner(new RoslynCSharpCompiler());
var result = await runner.ExecuteAsync(new ExecuteRequest { Code = "var x = 20;\nx + 22" });
// result.Success == true, result.Value == "42"
Contract, semantics and docs: https://github.com/IvanMurzak/Code-Exec. License: PolyForm Shield 1.0.0.
There are no supported framework assets in this package.
Learn more about Target Frameworks and .NET Standard.
-
.NETStandard 2.0
- com.IvanMurzak.CodeExec (>= 0.2.1)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.