Tag

脚本

Browsing articles related to 脚本.

2 articles
1 Current page
Hello .NET run file, goodbye csproj

Hello .NET run file, goodbye csproj

This article introduces the new file-based program feature of the .NET CLI, which allows developers to run C# source files directly without creating a project file. This feature works by generating a virtual project file in memory and supports NuGet dependencies and project property settings, providing convenience for developing scripts and simple applications. The article also looks forward to the future development directions of this feature, including target path extension, unified command-line arguments, performance improvements, and support for more file-based program commands.

WeihanLi amazingdotnet 5/24/2025 9:34 PM
C# Script

C# Script

In some cases, it is necessary to dynamically execute C# code during program runtime. For example, storing frequently changing algorithms in a configuration file and reading and executing them from the configuration file during runtime. C# scripts can be used to accomplish these tasks.

寻找无名的特质 12/24/2021 10:46 PM