<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>guitarrapc_tech</author_name>
  <author_url>https://blog.hatena.ne.jp/guitarrapc_tech/</author_url>
  <blog_title>tech.guitarrapc.cóm</blog_title>
  <blog_url>https://tech.guitarrapc.com/</blog_url>
  <categories>
    <anon>C#</anon>
    <anon>GitHubActions</anon>
  </categories>
  <description>以前にも軽く紹介する記事を書いているのですが、.NET 10から、C#のファイルベースプログラム実行機能が追加されました。C#にファイルベースプログラムが来ても.csファイルを用意して実行することを考えがちでしたが、そういえばパイプ入力でコードを渡して実行できます。例えば、次のようなコマンドが実行できます。 # BashやPowerShellで実行できる $ echo 'Console.WriteLine(&quot;FooBar&quot;);' | dotnet run - FooBar いい感じに見えますね。これまでC#はコンパイルが必要でスクリプト的な使い心地を得にくかったのですが、これを使うといい感じの…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Ftech.guitarrapc.com%2Fentry%2F2025%2F11%2F26%2F010000&quot; title=&quot;.NET 10のファイルベースプログラムをパイプ入力やGitHub Actionsで使う - tech.guitarrapc.cóm&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2025-11-26 01:00:00</published>
  <title>.NET 10のファイルベースプログラムをパイプ入力やGitHub Actionsで使う</title>
  <type>rich</type>
  <url>https://tech.guitarrapc.com/entry/2025/11/26/010000</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
