<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>aquarla</author_name>
  <author_url>https://blog.hatena.ne.jp/aquarla/</author_url>
  <blog_title>でぶぬる日記</blog_title>
  <blog_url>https://aquarla.hatenadiary.org/</blog_url>
  <categories>
    <anon>Ruby</anon>
    <anon>メモ</anon>
  </categories>
  <description>今後も便利に使えそうな気がするので、メモがてら残しておきます。あるディレクトリ配下にあり、ファイル名が&quot;*.rb&quot;に該当する全てのファイルに対して、「hoge1」→「hoge2」の一括置換を実行するコマンドです。 $ find . -type f -name '*.rb' -print0 | xargs -0 ruby -i -p -e '$_.gsub!(/hoge1/, &quot;hoge2&quot;)' ※ バックアップを残しておきたい場合は、「-i」のところを「-i.bak」とすると、元のファイルが「xxx.rb.bak」として保存されます。上記は、こちらにあったコマンドを参考に、Ruby用に書き直し…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Faquarla.hatenadiary.org%2Fentry%2F20110223%2F1298435030&quot; title=&quot;ディレクトリ内の複数のファイルを一括で文字列置換する方法 with Ruby - でぶぬる日記&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>2011-02-23 13:23:50</published>
  <title>ディレクトリ内の複数のファイルを一括で文字列置換する方法 with Ruby</title>
  <type>rich</type>
  <url>https://aquarla.hatenadiary.org/entry/20110223/1298435030</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
