<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>willnet</author_name>
  <author_url>https://blog.hatena.ne.jp/willnet/</author_url>
  <blog_title>おもしろwebサービス開発日記</blog_title>
  <blog_url>https://blog.willnet.in/</blog_url>
  <categories>
    <anon>rails</anon>
  </categories>
  <description>これまでrails上でのバッチ処理はscript/runnerを使って以下のようなコマンドで実行していました。 script/runner &quot;eval(IO.readlines('hoge.rb').join)&quot; でもこれ長いですよね。もっと短くする方法はないかなーと思ってscript/runner --helpしたら「こんな書き方もできるよ」とのこと。 #!/usr/bin/env /path/to/script/runner Product.find(:all).each { |p| p.price *= 2 ; p.save! } shebangにscript/runnerまでのパスを指…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fblog.willnet.in%2Fentry%2F20081126%2F1227683892&quot; title=&quot;script/runnerでのバッチファイル実行を短く書く - おもしろwebサービス開発日記&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>2008-11-26 16:18:12</published>
  <title>script/runnerでのバッチファイル実行を短く書く</title>
  <type>rich</type>
  <url>https://blog.willnet.in/entry/20081126/1227683892</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
