V2EX 13小时前
[.NET] csharp 这回真成了脚本语言: dotnet run app.cs
index_new5.html
../../../zaker_core/zaker_tpl_static/wap/tpl_guoji1.html

 

dotnet 10 支持直接运行 cs 源文件

引用三方包

#:package Humanizer@2.14.1using Humanizer;var dotNet9Released = DateTimeOffset.Parse("2024-12-03");var since = DateTimeOffset.Now - dotNet9Released;Console.WriteLine($"It has been {since.Humanize()} since .NET 9 was released.");

linux shebang

#!/usr/bin/dotnet runConsole.WriteLine("Hello from a C# script!");
chmod +x app.cs./app.cs

https://devblogs.microsoft.com/dotnet/announcing-dotnet-run-app

v 站的 dotnet 节点好冷清~~~

Fish AI Reader

Fish AI Reader

AI辅助创作,多种专业模板,深度分析,高质量内容生成。从观点提取到深度思考,FishAI为您提供全方位的创作支持。新版本引入自定义参数,让您的创作更加个性化和精准。

FishAI

FishAI

鱼阅,AI 时代的下一个智能信息助手,助你摆脱信息焦虑

联系邮箱 441953276@qq.com

相关标签

相关文章